P33M [Fri, 26 May 2017 11:50:31 +0000 (12:50 +0100)]
dwc_otg: fiq_fsm: Make isochronous compatibility checks work properly
Get rid of the spammy printk and local pointer mangling.
Also, there is a nominal benefit for using fiq_fsm for isochronous
transfers in FS mode (~1.1k IRQs per second vs 2.1k IRQs per second)
so remove the root port speed check.
Stefan Tatschner [Mon, 29 May 2017 19:46:16 +0000 (21:46 +0200)]
Add device tree config for htu21
See: https://github.com/raspberrypi/linux/pull/2041
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Wed, 31 May 2017 14:27:39 +0000 (15:27 +0100)]
BCM270X_DT: Improve i2c-sensor and i2c-rtc overlay
Use the "__dormant__" feature to permit multiple instances of each
overlay, which is more useful now that changing the "reg" property
also changes the node address. Although the overlay grows slightly,
when applied only the requested node is included.
Usage does not change, except that the "lm75addr" parameter of the
i2c-sensor overlay has been deprecated in favour of the generic
"addr" parameter.
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Wed, 31 May 2017 08:33:55 +0000 (09:33 +0100)]
config: Adding SENSOR_JC42
The jc42 module supports a number of I2C-based temperature
sensor modules.
[ DM_RAID0 config lost because now selected by DM_RAID ]
See: https://github.com/raspberrypi/linux/issues/2046
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
P33M [Thu, 25 May 2017 15:04:53 +0000 (16:04 +0100)]
dwc_otg: make periodic scheduling behave properly for FS buses
If the root port is in full-speed mode, transfer times at 12mbit/s
would be calculated but matched against high-speed quotas.
Reinitialise hcd->frame_usecs[i] on each port enable event so that
full-speed bandwidth can be tracked sensibly.
Also, don't bother using the FIQ for transfers when in full-speed
mode - at the slower bus speed, interrupt frequency is reduced by
an order of magnitude.
Related issue: https://github.com/raspberrypi/linux/issues/2020
popcornmix [Mon, 14 Jul 2014 21:02:09 +0000 (22:02 +0100)]
hid: Reduce default mouse polling interval to 60Hz
Reduces overhead when using X
Tobias Jakobi [Sat, 25 Feb 2017 19:27:27 +0000 (20:27 +0100)]
HID: usbhid: extend polling interval configuration to joysticks
For mouse devices we can currently change the polling interval
via usbhid.mousepoll. Implement the same thing for joysticks, so
users can reduce input latency this way.
This has been tested with a Logitech RumblePad 2 with jspoll=2,
resulting in a polling rate of 500Hz (verified with evhz).
Signed-off-by: Tobias Jakobi <tjakobi@math.uni-bielefeld.de>
Acked-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
popcornmix [Wed, 24 May 2017 17:06:02 +0000 (18:06 +0100)]
Revert "hid: Reduce default mouse polling interval to 60Hz"
This reverts commit
b45c0448b60d691508251cdccf242ea43bbabb14.
Phil Elwell [Mon, 22 May 2017 12:56:41 +0000 (13:56 +0100)]
clk: bcm2835: Minimise clock jitter for PCM clock
Fractional clock dividers generate accurate average frequencies but
with jitter, particularly when the integer divisor is small.
Introduce a new metric of clock accuracy to penalise clocks with a good
average but worse jitter compared to clocks with an average which is no
better but with lower jitter. The metric is the ideal rate minus the
worse deviation from that ideal using the nearest integer divisors.
Use this metric for parent selection for clocks requiring low jitter
(currently just PCM).
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Anton Onishchenko [Tue, 23 May 2017 15:55:46 +0000 (18:55 +0300)]
mpu6050 device tree overlay (#2031)
Add overlay and config options for InvenSense MPU6050 6-axis motion
detector.
popcornmix [Mon, 22 May 2017 12:35:28 +0000 (13:35 +0100)]
config: Add CONFIG_IPV6_SIT_6RD
popcornmix [Mon, 22 May 2017 14:28:27 +0000 (15:28 +0100)]
config: Add CONFIG_IPV6_ROUTE_INFO
Liviu Dudau [Wed, 1 Mar 2017 12:26:28 +0000 (12:26 +0000)]
ASoC: TLV320AIC23: Unquote NULL from control name
commit
a03faba972cb0f9b3a46d8054e674d5492e06c38 upstream.
Without this I am getting the following messages at boot on my Trimslice:
tlv320aic23-codec 2-001a: Control not supported for path LLINEIN -> [NULL] -> Line Input
tlv320aic23-codec 2-001a: ASoC: no dapm match for LLINEIN --> NULL --> Line Input
tlv320aic23-codec 2-001a: ASoC: Failed to add route LLINEIN -> NULL -> Line Input
tlv320aic23-codec 2-001a: Control not supported for path RLINEIN -> [NULL] -> Line Input
tlv320aic23-codec 2-001a: ASoC: no dapm match for RLINEIN --> NULL --> Line Input
tlv320aic23-codec 2-001a: ASoC: Failed to add route RLINEIN -> NULL -> Line Input
tlv320aic23-codec 2-001a: Control not supported for path MICIN -> [NULL] -> Mic Input
tlv320aic23-codec 2-001a: ASoC: no dapm match for MICIN --> NULL --> Mic Input
tlv320aic23-codec 2-001a: ASoC: Failed to add route MICIN -> NULL -> Mic Input
tegra-snd-trimslice sound: tlv320aic23-hifi <->
70002800.i2s mapping ok
Signed-off-by: Liviu Dudau <liviu@dudau.co.uk>
Signed-off-by: Mark Brown <broonie@kernel.org>
Phil Elwell [Sat, 20 May 2017 21:10:14 +0000 (22:10 +0100)]
overlays: README: remove vestigial SDIO parameters
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Karl Palsson [Tue, 18 Mar 2014 23:33:27 +0000 (23:33 +0000)]
usb/serial/ch341: Add parity support
Based on wireshark packet traces from a windows machine.
ch340 and ch341 both seem to support all parity modes, but only the ch341
appears to support variable data bits and variable stop bits, so those are left
unimplemented, as before.
Tested on a generic usb-rs485 dongle with the chip label scratched off, and
some Modbus/RTU devices that required various parity settings.
Signed-off-by: Karl Palsson <karlp@tweak.net.au>
popcornmix [Thu, 18 May 2017 10:40:43 +0000 (11:40 +0100)]
config: Add FB_TFT_ST7789V module
Phil Elwell [Fri, 19 May 2017 14:07:27 +0000 (15:07 +0100)]
serial: 8250: Add CAP_MINI, set for bcm2835aux
The AUX/mini-UART in the BCM2835 family of procesors is a cut-down
8250 clone. In particular it is lacking support for the following
features: CSTOPB PARENB PARODD CMSPAR CS5 CS6
Add a new capability (UART_CAP_MINI) that exposes the restrictions to
the user of the termios API by turning off the unsupported features in
the request.
N.B. It is almost possible to automatically discover the missing
features by reading back the LCR register, but the CSIZE bits don't
cooperate (contrary to the documentation, both bits are significant,
but CS5 and CS6 are mapped to CS7) and the code is much longer.
See: https://github.com/raspberrypi/linux/issues/1561
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Ed Blake [Thu, 10 Nov 2016 18:07:54 +0000 (18:07 +0000)]
serial: 8250: Add IrDA to UART capabilities
commit
98838d95075a5295f3478ceba18bcccf472e30f4 upstream.
Add an IrDA UART capability flag and change the type of
uart_8250_port.capabilities to be u32 rather than unsigned short to
accommodate the additional flag.
Signed-off-by: Ed Blake <ed.blake@imgtec.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
chenzhiwo [Wed, 17 May 2017 08:34:57 +0000 (16:34 +0800)]
Add device tree overlay for GPIO connected rotary encoder.
See Documentation/input/rotary-encoder.txt for more information.
popcornmix [Tue, 16 May 2017 18:34:52 +0000 (19:34 +0100)]
config: Add CONFIG_I2C_ROBOTFUZZ_OSIF
popcornmix [Tue, 16 May 2017 14:58:00 +0000 (15:58 +0100)]
config: Add CONFIG_TOUCHSCREEN_EDT_FT5X06
popcornmix [Tue, 16 May 2017 15:55:36 +0000 (16:55 +0100)]
config: Drop CONFIG_TOUCHSCREEN_EKTF2127
Ahmet Inan [Mon, 15 May 2017 15:10:53 +0000 (17:10 +0200)]
overlays: Add Goodix overlay
Add support for I2C connected Goodix gt9271 multiple touch controller using
GPIOs 4 and 17 (pins 7 and 11 on GPIO header) for interrupt and reset.
Signed-off-by: Ahmet Inan <inan@distec.de>
Ahmet Inan [Mon, 15 May 2017 14:55:56 +0000 (16:55 +0200)]
config: Add Goodix touch controller module
Signed-off-by: Ahmet Inan <inan@distec.de>
Eric Anholt [Mon, 15 May 2017 18:35:13 +0000 (11:35 -0700)]
BCM270X: Drop position requirement for CMA in VC4 overlay.
No longer necessary since
2aefcd576195a739a7a256099571c9c4a401005f,
and will probably let peeople that want to choose a larger CMA
allocation (particularly on pi0/1).
Signed-off-by: Eric Anholt <eric@anholt.net>
Eric Anholt [Mon, 15 May 2017 16:28:36 +0000 (09:28 -0700)]
drm/vc4: Mark the device as active when enabling runtime PM.
Failing to do so meant that we got a resume() callback on first use of
the device, so we would leak the bin BO that we allocated during
probe.
Signed-off-by: Eric Anholt <eric@anholt.net>
Fixes: 553c942f8b2c ("drm/vc4: Allow using more than 256MB of CMA memory.")
P33M [Mon, 15 May 2017 13:51:42 +0000 (14:51 +0100)]
dwc_otg: remove unnecessary dma-mode channel halts on disconnect interrupt
Host channels are already halted in kill_urbs_in_qh_list() with the
subsequent interrupt processing behaving as if the URB was dequeued
via HCD callback.
There's no need to clobber the host channel registers a second time
as this exposes races between the driver and host channel resulting
in hcd->free_hc_list becoming corrupted.
P33M [Mon, 15 May 2017 13:27:48 +0000 (14:27 +0100)]
dwc_otg: delete hcd->channel_lock
The lock serves no purpose as it is only held while the HCD spinlock
is already being held.
P33M [Fri, 12 May 2017 11:24:00 +0000 (12:24 +0100)]
dwc_otg: fix several potential crash sources
On root port disconnect events, the host driver state is cleared and
in-progress host channels are forcibly stopped. This doesn't play
well with the FIQ running in the background, so:
- Guard the disconnect callback with both the host spinlock and FIQ
spinlock
- Move qtd dereference in dwc_otg_handle_hc_fsm() after the early-out
so we don't dereference a qtd that has gone away
- Turn catch-all BUG()s in dwc_otg_handle_hc_fsm() into warnings.
Phil Elwell [Thu, 11 May 2017 21:00:20 +0000 (22:00 +0100)]
SQUASH: BCM270X_DT: Fix typo in mmc overlay
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Thu, 11 May 2017 15:58:16 +0000 (16:58 +0100)]
BCM270X_DT: Tidy up mmc, sdhost, sdio overlays
The mmc, sdhost, sdio and sdio-1bit overlays had a few
anachronisms and oddities which were overdue for fixing.
The new versions should be functionally equivalent.
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
popcornmix [Wed, 10 May 2017 11:47:46 +0000 (12:47 +0100)]
dwcotg: Allow to build without FIQ on ARM64
Signed-off-by: popcornmix <popcornmix@gmail.com>
Nisar Sayed [Tue, 9 May 2017 17:51:42 +0000 (18:51 +0100)]
According to RFC 2460, IPv6 UDP calculated checksum yields a result
of zero must be changed to 0xffff, however this feature is not
supported by smsc95xx family hence enable csum offload only for
IPv4 TCP/UDP packets.
Signed-off-by: Nisar Sayed <Nisar.Sayed@microchip.com>
Reported-by: popcorn mix <popcornmix@gmail.com>
Phil Elwell [Mon, 8 May 2017 15:43:40 +0000 (16:43 +0100)]
irq_bcm2836: Send event when onlining sleeping cores
In order to reduce power consumption and bus traffic, it is sensible
for secondary cores to enter a low-power idle state when waiting to
be started. The wfe instruction causes a core to wait until an event
or interrupt arrives before continuing to the next instruction.
The sev instruction sends a wakeup event to the other cores, so call
it from bcm2836_smp_boot_secondary, the function that wakes up the
waiting cores during booting.
It is harmless to use this patch without the corresponding change
adding wfe to the ARMv7/ARMv8-32 stubs, but if the stubs are updated
and this patch is not applied then the other cores will sleep forever.
See: https://github.com/raspberrypi/linux/issues/1989
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Mon, 8 May 2017 15:30:18 +0000 (16:30 +0100)]
ARM: dts: bcm283x: Reserve first page for firmware
The Raspberry Pi startup stub files for multi-core BCM27XX processors
make the secondary CPUs spin until the corresponding mailbox is
written. These stubs are loaded at physical address 0x00000xxx (as seen
by the ARMs), but this page will be reused by the kernel unless it is
explicitly reserved, causing the waiting cores to execute random code.
Use the /memreserve/ Device Tree directive to mark the first page as
off-limits to the kernel.
See: https://github.com/raspberrypi/linux/issues/1989
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
popcornmix [Fri, 5 May 2017 12:23:10 +0000 (13:23 +0100)]
Revert "serial: 8250: Don't crash when nr_uarts is 0"
This reverts commit
9c297d9ebd0d8c6d5e6e8675d527d6a221613abc.
popcornmix [Thu, 4 May 2017 16:38:22 +0000 (17:38 +0100)]
bcm2708_fb: Avoid firmware mbox call in vc_mem_copy
If firmware has locked up it is useful to get vcdbg log out without a firmware mbox response.
Issue the mbox call at probe time instead.
Signed-off-by: popcornmix <popcornmix@gmail.com>
popcornmix [Tue, 2 May 2017 15:36:05 +0000 (16:36 +0100)]
vcsm: Treat EBUSY as success rather than SIGBUS
Currently if two cores access the same page concurrently one will return VM_FAULT_NOPAGE
and the other VM_FAULT_SIGBUS crashing the user code.
Also report when mapping fails.
Signed-off-by: popcornmix <popcornmix@gmail.com>
P33M [Thu, 4 May 2017 13:56:08 +0000 (14:56 +0100)]
fiq_fsm: Use correct states when starting isoc OUT transfers (#1991)
* fiq_fsm: Use correct states when starting isoc OUT transfers
In fiq_fsm_start_next_periodic() if an isochronous OUT transfer
was selected, no regard was given as to whether this was a single-packet
transfer or a multi-packet staged transfer.
For single-packet transfers, this had the effect of repeatedly sending
OUT packets with bogus data and lengths.
Eventually if the channel was repeatedly enabled enough times, this
would lock up the OTG core and no further bus transfers would happen.
Set the FSM state up properly if we select a single-packet transfer.
Fixes https://github.com/raspberrypi/linux/issues/1842
P33M [Tue, 2 May 2017 15:31:15 +0000 (16:31 +0100)]
dwc_otg: fix split transaction data toggle handling around dequeues
See https://github.com/raspberrypi/linux/issues/1709
Fix several issues regarding endpoint state when URBs are dequeued
- If the HCD is disconnected, flush FIQ-enabled channels properly
- Save the data toggle state for bulk endpoints if the last transfer
from an endpoint where URBs were dequeued returned a data packet
- Reset hc->start_pkt_count properly in assign_and_init_hc()
popcornmix [Tue, 18 Apr 2017 20:43:46 +0000 (21:43 +0100)]
vc4_fkms: Apply firmware overscan offset to hardware cursor
P33M [Thu, 27 Apr 2017 15:24:34 +0000 (16:24 +0100)]
dwc_otg: make nak_holdoff work as intended with empty queues
If URBs reading from non-periodic split endpoints were dequeued and
the last transfer from the endpoint was a NAK handshake, the resulting
qh->nak_frame value was stale which would result in unnecessarily long
polling intervals for the first subsequent transfer with a fresh URB.
Fixup qh->nak_frame in dwc_otg_hcd_urb_dequeue and also guard against
a case where a single URB is submitted to the endpoint, a NAK was
received on the transfer immediately prior to receiving data and the
device subsequently resubmits another URB past the qh->nak_frame interval.
Fixes https://github.com/raspberrypi/linux/issues/1709
Phil Elwell [Wed, 26 Apr 2017 16:28:47 +0000 (17:28 +0100)]
clk: bcm2835: Limit PCM clock to OSC and PLLD_PER
It is unwise to use sources other than the oscillator and PLLD_PER for
the PCM peripheral (and perhaps others - TBD) because their rate can
change and they may even be switched off, so explicitly restrict the
choice using dummy entries in the list of potential parents (item index
is significant).
See: https://github.com/raspberrypi/linux/issues/1949
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
popcornmix [Wed, 26 Apr 2017 15:51:48 +0000 (16:51 +0100)]
dwc_otg: Add the dependency on FIQ
Signed-off-by: popcornmix <popcornmix@gmail.com>
Scott Ellis [Tue, 25 Apr 2017 17:05:42 +0000 (13:05 -0400)]
BCM270X_DT: Add tmp102 to i2c sensor overlay
Signed-off-by: Scott Ellis <scott@jumpnowtek.com>
Scott Ellis [Tue, 25 Apr 2017 14:46:09 +0000 (10:46 -0400)]
config: Enable TI TMP102 temp sensor module
Signed-off-by: Scott Ellis <scott@jumpnowtek.com>
Phil Elwell [Sun, 23 Apr 2017 18:38:06 +0000 (19:38 +0100)]
config: Add CONFIG_BMP280 (and CONFIG_BMP280_I2C)
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Sun, 23 Apr 2017 18:36:53 +0000 (19:36 +0100)]
BCM270X_DT: Add bme280 and bmp180 to i2c-sensor overlay
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
James Hughes [Wed, 19 Apr 2017 10:13:40 +0000 (11:13 +0100)]
smsc95xx: Use skb_cow_head to deal with cloned skbs
The driver was failing to check that the SKB wasn't cloned
before adding checksum data.
Replace existing handling to extend/copy the header buffer
with skb_cow_head.
Signed-off-by: James Hughes <james.hughes@raspberrypi.org>
Acked-by: Eric Dumazet <edumazet@google.com>
Acked-by: Woojung Huh <Woojung.Huh@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Eric Anholt [Thu, 13 Apr 2017 00:52:56 +0000 (17:52 -0700)]
panel-raspberrypi-touchscreen: Fix NULL deref if probe order goes wrong.
If the i2c driver hadn't pobed before the panel driver probes, then
the client would be NULL but we were looking for an ERR_PTR in the
error case.
Signed-off-by: Eric Anholt <eric@anholt.net>
Boris Brezillon [Thu, 2 Feb 2017 10:37:36 +0000 (11:37 +0100)]
ARM: dts: bcm283x: Add HDMI audio related properties
Add the dmas and dma-names properties to support HDMI audio.
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
(cherry picked from commit
d46d2c6380c10e80e99f6af9067356128bffac6b)
Eric Anholt [Mon, 27 Feb 2017 20:28:02 +0000 (12:28 -0800)]
drm/vc4: Add HDMI audio support
The HDMI encoder IP embeds all needed blocks to output audio, with a
custom DAI called MAI moving audio between the two parts of the HDMI
core. This driver now exposes a sound card to let users stream audio
to their display.
Using the hdmi-codec driver has been considered here, but MAI meant
having to significantly rework hdmi-codec, and it would have left
little shared code with the I2S mode anyway.
The encoder requires that the audio be SPDIF-formatted frames only,
which alsalib will format-convert for us.
This patch is the combined work of Eric Anholt (initial register setup
with a separate dmaengine driver and using simple-audio-card) and
Boris Brezillon (moving it all into HDMI, massive debug to get it
actually working), and which Eric has the permission to release.
v2: Drop "-audio" from sound card name, since that's already implied
(suggestion by Boris)
Signed-off-by: Eric Anholt <eric@anholt.net>
Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20170227202803.12855-2-eric@anholt.net
Eric Anholt [Thu, 30 Mar 2017 17:23:27 +0000 (10:23 -0700)]
Revert "drm/vc4: Verify at boot that CMA doesn't cross a 256MB boundary."
This reverts commit
016c804fa69381bd23a1a13cba08a3c4557fcdff. The
restriction was lifted by the previous commit.
Eric Anholt [Tue, 7 Mar 2017 22:51:03 +0000 (14:51 -0800)]
drm/vc4: Allow using more than 256MB of CMA memory.
Until now, we've had to limit Raspberry Pi to 256MB of CMA memory to
keep from triggering the hardware addressing bug between of the tile
binner of the tile alloc memory (where the top 4 bits come from the
tile state data array's address).
To work around that and allow more memory to be reserved for graphics,
allocate a single BO to store tile state data arrays and tile
alloc/overflow memory while the GPU is active, and make sure that that
one BO doesn't happen to cross a 256MB boundary. With that in place,
we can allocate textures and shaders anywhere in system memory (still
contiguous, of course).
Signed-off-by: Eric Anholt <eric@anholt.net>
Yasunari Takiguchi [Thu, 22 Dec 2016 06:34:12 +0000 (15:34 +0900)]
BCM2708: Add Raspberry Pi TV HAT Device Tree Support
This is an EXAMPLE CODE of Raspberry Pi TV HAT device tree overlay.
Although this is not a part of our release code, it has been used to verify
CXD2880 device driver with TV HAT.
Add the following line to /boot/config.txt to enable TV HAT:
dtoverlay=rpi-tv
Reboot Raspberry Pi and check the existance of /proc/device-tree/soc/spi@
7e204000/cxd2880@0.
If exists, the installation is successful. you should be able to find the following three files.
/dev/dvb/adapter0/frontend0
/dev/dvb/adapter0/demux0
/dev/dvb/adapter0/dvr0
Signed-off-by: Yasunari Takiguchi <Yasunari.Takiguchi@sony.com>
Signed-off-by: Masayuki Yamamoto <Masayuki.Yamamoto@sony.com>
Signed-off-by: Hideki Nozawa <Hideki.Nozawa@sony.com>
Signed-off-by: Kota Yonezawa <Kota.Yonezawa@sony.com>
Signed-off-by: Toshihiko Matsumoto <Toshihiko.Matsumoto@sony.com>
Signed-off-by: Satoshi Watanabe <Satoshi.C.Watanabe@sony.com>
Yasunari Takiguchi [Fri, 14 Apr 2017 09:43:57 +0000 (10:43 +0100)]
This is the driver for Sony CXD2880 DVB-T2/T tuner + demodulator.
It includes the CXD2880 driver and the CXD2880 SPI adapter.
The current CXD2880 driver version is 1.4.1 - 1.0.1 released
on April 13, 2017.
Signed-off-by: Yasunari Takiguchi <Yasunari.Takiguchi@sony.com>
Signed-off-by: Masayuki Yamamoto <Masayuki.Yamamoto@sony.com>
Signed-off-by: Hideki Nozawa <Hideki.Nozawa@sony.com>
Signed-off-by: Kota Yonezawa <Kota.Yonezawa@sony.com>
Signed-off-by: Toshihiko Matsumoto <Toshihiko.Matsumoto@sony.com>
Signed-off-by: Satoshi Watanabe <Satoshi.C.Watanabe@sony.com>
Matt Flax [Tue, 4 Apr 2017 09:23:04 +0000 (19:23 +1000)]
Audioinjector octo : Make the playback and capture symmetric
This patch ensures that the sample rate and channel count of the audioinjector
octo sound card are symmetric.
Matt Flax [Tue, 4 Apr 2017 09:20:59 +0000 (19:20 +1000)]
Audioinjector : make the octo and pi sound cards have different driver names
This patch gives the audioinjector octo and pi soundcards different driver
names. This allows both the be loaded without clashing.
BabuSubashChandar [Fri, 31 Mar 2017 19:16:52 +0000 (00:46 +0530)]
Add clock changes and mute gpios (#1938)
Also improve code style and adhere to ALSA coding conventions.
Signed-off-by: Baswaraj K <jaikumar@cem-solutions.net>
Reviewed-by: Vijay Kumar B. <vijaykumar@zilogic.com>
Reviewed-by: Raashid Muhammed <raashidmuhammed@zilogic.com>
BabuSubashChandar C [Thu, 30 Mar 2017 14:47:27 +0000 (20:17 +0530)]
Add support for new clock rate and mute gpios.
Signed-off-by: Baswaraj K <jaikumar@cem-solutions.net>
Reviewed-by: Deepak <deepak@zilogic.com>
Reviewed-by: BabuSubashChandar <babusubashchandar@zilogic.com>
Matt Flax [Thu, 30 Mar 2017 00:43:57 +0000 (11:43 +1100)]
Audioinjector Octo : add extra sample rates, fix rst and use bcm270x regs
This patch adds new sample rates to the Audioinjector Octo sound card. The
new supported rates are (in kHz) :
96, 48, 32, 24, 16, 8, 88.2, 44.1, 29.4, 22.05, 14.7
This patch also replaces the regulators in the device tree overlay with
the ones declared in bcm270x.dtsi include file.
This patch also adds an extra codec reset and delay on probe.
Phil Elwell [Tue, 28 Mar 2017 16:41:30 +0000 (17:41 +0100)]
leds-gpio: Remove stray assignment to brightness_set
The brightness_set method is intended for use cases that must not
block, and can only be used if the GPIO provider can never sleep.
Remove an accidental initialisation (a copy-and-paste error) that
sets it regardless, which has been seen to cause crashes with the
gpio expander driver.
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Tue, 28 Mar 2017 13:22:20 +0000 (14:22 +0100)]
BCM270X_DT: Allow multiple instances of w1-gpio overlays
Upcoming firmware will modify the address portion of node names when
their "reg" property is written by a dtparam. Modify the w1-gpio
overlays to write the gpiopin parameter value to "reg" properties, so
that multiple instances can be loaded simultaneously.
Note: The value of the "address" is unimportant - the w1 subsystem
assigns instance numbers to buses sequentially from 1, and it is
not necessary to know which bus a device is on in order to find it.
BabuSubashChandar [Tue, 28 Mar 2017 14:34:42 +0000 (20:04 +0530)]
Add support for Allo Boss DAC add-on board for Raspberry Pi. (#1924)
Signed-off-by: Baswaraj K <jaikumar@cem-solutions.net>
Reviewed-by: Deepak <deepak@zilogic.com>
Reviewed-by: BabuSubashChandar <babusubashchandar@zilogic.com>
Raashid Muhammed [Mon, 27 Mar 2017 07:05:00 +0000 (12:35 +0530)]
Add support for Allo Piano DAC 2.1 plus add-on board for Raspberry Pi.
The Piano DAC 2.1 has support for 4 channels with subwoofer.
Signed-off-by: Baswaraj K <jaikumar@cem-solutions.net>
Reviewed-by: Vijay Kumar B. <vijaykumar@zilogic.com>
Reviewed-by: Raashid Muhammed <raashidmuhammed@zilogic.com>
Peter Malkin [Mon, 27 Mar 2017 23:38:21 +0000 (16:38 -0700)]
Driver support for Google voiceHAT soundcard.
Matt Flax [Mon, 27 Mar 2017 11:27:26 +0000 (22:27 +1100)]
AudioInjector Octo : Consolidate sample rates and add a codec reset.
This patch consolidates the sample rates which the audioinjector.net octo
sound card can use. The consolidation of sample rates are due to the
capabilities of the cs42448 codec.
This codec also requires a hard reset using the GPIO pin 5 upon probe.
Matt Flax [Mon, 27 Mar 2017 11:26:49 +0000 (22:26 +1100)]
Audioinjector addons dts : add reset and regulators for the Octo product.
This patch adds a reset GPIO for the AudioInjector.net octo sound card.
This patch adds missing regulators for the cs42448 codec.
Phil Elwell [Thu, 23 Mar 2017 17:08:44 +0000 (17:08 +0000)]
BCM270X_DT: Enable AUX interrupt controller in DT
See: https://github.com/raspberrypi/linux/issues/1484
https://github.com/raspberrypi/linux/issues/1573
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Thu, 23 Mar 2017 16:34:46 +0000 (16:34 +0000)]
bcm2835-aux: Add aux interrupt controller
The AUX block has a shared interrupt line with a register indicating
which devices have active IRQs. Expose this as a nested interrupt
controller to avoid sharing problems.
See: https://github.com/raspberrypi/linux/issues/1484
https://github.com/raspberrypi/linux/issues/1573
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Thu, 23 Mar 2017 10:06:56 +0000 (10:06 +0000)]
ASoC: Add prompt for ICS43432 codec
Without a prompt string, a config setting can't be included in a
defconfig. Give CONFIG_SND_SOC_ICS43432 a prompt so that Pi soundcards
can use the driver.
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Fri, 17 Mar 2017 12:24:41 +0000 (12:24 +0000)]
config: Make spidev a loadable module
spidev isn't required early in the boot process, and not all users
need it (spi_bcm2835 is a module), so make it a loadable module.
See: https://github.com/raspberrypi/linux/issues/1897
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Dave Stevenson [Wed, 15 Mar 2017 11:12:40 +0000 (11:12 +0000)]
bcm2835-camera: Correct port_parameter_get return value
The API for port_parameter_get() requires that the
filled length is returned, or if insufficient space
that the required space is returned.
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
Dave Stevenson [Tue, 14 Mar 2017 14:23:06 +0000 (14:23 +0000)]
bcm2835-gpio-exp: Copy/paste error adding base twice
brcmexp_gpio_set was adding gpio->gc.base to the offset
twice, so passing an invalid number to the mailbox service.
The firmware treated it modulo-8 anyway, but was logging an
assert every time.
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
Phil Elwell [Tue, 14 Mar 2017 09:10:05 +0000 (09:10 +0000)]
BCM270X_DT: Add lm75 to i2c-sensor overlay
See: https://www.raspberrypi.org/forums/viewtopic.php?f=107&t=177236
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Dave Stevenson [Tue, 7 Mar 2017 12:18:20 +0000 (12:18 +0000)]
BCM270X_DT: Invert Pi3 power LED to match fw change
Firmware expgpio driver reworked due to complaint over
hotplug detect.
Requires power LED to change sense as firmware is no longer
inverting the read value.
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
Ping-Ke Shih [Wed, 28 Dec 2016 21:40:04 +0000 (15:40 -0600)]
rtlwifi: Fix alignment issues
commit
40b368af4b750863b2cb66a3a9513241db2f0793 upstream.
The addresses of Wlan NIC registers are natural alignment, but some
drivers have bugs. These are evident on platforms that need natural
alignment to access registers. This change contains the following:
1. Function _rtl8821ae_dbi_read() is used to read one byte from DBI,
thus it should use rtl_read_byte().
2. Register 0x4C7 of 8192ee is single byte.
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
K. Y. Srinivasan [Fri, 23 Dec 2016 00:54:03 +0000 (16:54 -0800)]
Drivers: hv: util: Backup: Fix a rescind processing issue
commit
d77044d142e960f7b5f814a91ecb8bcf86aa552c upstream.
VSS may use a char device to support the communication between
the user level daemon and the driver. When the VSS channel is rescinded
we need to make sure that the char device is fully cleaned up before
we can process a new VSS offer from the host. Implement this logic.
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
K. Y. Srinivasan [Fri, 23 Dec 2016 00:54:02 +0000 (16:54 -0800)]
Drivers: hv: util: Fcopy: Fix a rescind processing issue
commit
20951c7535b5e6af46bc37b7142105f716df739c upstream.
Fcopy may use a char device to support the communication between
the user level daemon and the driver. When the Fcopy channel is rescinded
we need to make sure that the char device is fully cleaned up before
we can process a new Fcopy offer from the host. Implement this logic.
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
K. Y. Srinivasan [Fri, 23 Dec 2016 00:54:01 +0000 (16:54 -0800)]
Drivers: hv: util: kvp: Fix a rescind processing issue
commit
5a66fecbf6aa528e375cbebccb1061cc58d80c84 upstream.
KVP may use a char device to support the communication between
the user level daemon and the driver. When the KVP channel is rescinded
we need to make sure that the char device is fully cleaned up before
we can process a new KVP offer from the host. Implement this logic.
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
K. Y. Srinivasan [Fri, 23 Dec 2016 00:54:00 +0000 (16:54 -0800)]
Drivers: hv: vmbus: Fix a rescind handling bug
commit
ccb61f8a99e6c29df4fb96a65dad4fad740d5be9 upstream.
The host can rescind a channel that has been offered to the
guest and once the channel is rescinded, the host does not
respond to any requests on that channel. Deal with the case where
the guest may be blocked waiting for a response from the host.
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
popcornmix [Sun, 5 Mar 2017 11:46:41 +0000 (11:46 +0000)]
config: Add RTL8XXXU wifi module
John Greb [Wed, 8 Mar 2017 15:12:29 +0000 (15:12 +0000)]
Match dwc2 device-tree fifo sizes to the hardware values.
Since commit
aa381a7259c3f53727bcaa8c5f9359e940a0e3fd was reverted with
3fa9538539ac737096c81f3315a14670b1609092 the g-tx-fifo-size array in the device-tree needs to match the preset values in the bcm2835.
Resolves https://github.com/raspberrypi/linux/issues/1876
Khem Raj [Sat, 11 Feb 2017 01:57:08 +0000 (17:57 -0800)]
build/arm64: Add rules for .dtbo files for dts overlays
We now create overlays as .dtbo files.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Dave Stevenson [Fri, 10 Mar 2017 14:43:15 +0000 (14:43 +0000)]
bcm2835-v4l2: Fix buffer overflow problem
https://github.com/raspberrypi/linux/issues/1447
port_parameter_get() failed to account for the header
(u32 id and u32 size) in the size before memcpying
the response into the response buffer, so overrunning
the provided buffer by 8 bytes.
Account for those bytes, and also a belt-and-braces
check to ensure we never copy more than *value_size
bytes into value.
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
Matt Flax [Wed, 8 Mar 2017 10:13:24 +0000 (21:13 +1100)]
ASoC: bcm2835_i2s.c: relax the ch2 register setting for 8 channels
This patch allows ch2 registers to be set for 8 channels of audio.
Matt Flax [Wed, 8 Mar 2017 09:04:13 +0000 (20:04 +1100)]
Add support for the AudioInjector.net Octo sound card
Eric Anholt [Mon, 6 Mar 2017 20:17:16 +0000 (12:17 -0800)]
panel-raspberrypi-touchscreen: Round up clk rate to fix DSI panel.
Commit
488f9bc8e3def93e0baef53cee2026c2cb0d8956 slightly increased the
reported rate of PLLD, so the clk driver decided that PLLD/3/8 was now
higher than our requested pixel clock rate and rejected it in favor of
PLLD/4/8, which then ran the pixel clock way out of spec.
By bumping the requested clock rate just slightly, we get back to
PLLD/3/8 like we wanted and the panel displays content again.
Signed-off-by: Eric Anholt <eric@anholt.net>
Michael Zoran [Fri, 24 Feb 2017 01:54:31 +0000 (17:54 -0800)]
drm/vc4: Don't wait for vblank when updating the cursor
Commonly used desktop environments such as xfce4 and gnome
on debian sid can flood the graphics drivers with cursor
updates. Because the current implementation is waiting
for a vblank between cursor updates, this will cause the
display to hang for a long time since a typical refresh
rate is only 60Hz.
This is unnecessary and unexpected by user mode software,
so simply swap out the cursor frame buffer without waiting.
Signed-off-by: Michael Zoran <mzoran@crowfest.net>
Reviewed-by: Eric Anholt <eric@anholt.net>
Phil Elwell [Tue, 7 Mar 2017 19:48:23 +0000 (19:48 +0000)]
config: Add CONFIG_CRYPTO_LZ4
Enabling this options allows LZ4 memory compression.
Fixes: https://github.com/raspberrypi/linux/issues/1875
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Mon, 6 Mar 2017 09:06:18 +0000 (09:06 +0000)]
clk-bcm2835: Read max core clock from firmware
The VPU is responsible for managing the core clock, usually under
direction from the bcm2835-cpufreq driver but not via the clk-bcm2835
driver. Since the core frequency can change without warning, it is
safer to report the maximum clock rate to users of the core clock -
I2C, SPI and the mini UART - to err on the safe side when calculating
clock divisors.
If the DT node for the clock driver includes a reference to the
firmware node, use the firmware API to query the maximum core clock
instead of reading the divider registers.
Prior to this patch, a "100KHz" I2C bus was sometimes clocked at about
160KHz. In particular, switching to the 4.9 kernel was likely to break
SenseHAT usage on a Pi3.
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Tue, 24 May 2016 15:30:05 +0000 (16:30 +0100)]
BCM270X_DT: Add bcm2708-rpi-0-w.dts
Add DT support for the Pi Zero W. N.B. It will not be loaded
automatically without a corresponding change to the firmware.
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Dave Stevenson [Mon, 20 Feb 2017 17:01:21 +0000 (17:01 +0000)]
bcm2835-gpio-exp: Driver for GPIO expander via mailbox service
Pi3 and Compute Module 3 have a GPIO expander that the
VPU communicates with.
There is a mailbox service that now allows control of this
expander, so add a kernel driver that can make use of it.
Pwr_led node added to device-tree for Pi3.
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
Dave Stevenson [Mon, 13 Feb 2017 13:11:41 +0000 (13:11 +0000)]
BCM2835-V4L2: Correctly denote key frames in encoded data
Forward MMAL key frame flags to the V4L2 buffers.
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
Dave Stevenson [Mon, 13 Feb 2017 11:10:50 +0000 (11:10 +0000)]
BCM2835-V4L2: Ensure H264 header bytes get a sensible timestamp
H264 header come off VC with 0 timestamps, which means they get a
strange timestamp when processed with VC/kernel start times,
particularly if used with the inline header option.
Remember the last frame timestamp and use that if set, or otherwise
use the kernel start time.
https://github.com/raspberrypi/linux/issues/1836
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
Phil Elwell [Wed, 1 Mar 2017 16:07:39 +0000 (16:07 +0000)]
amba_pl011: Round input clock up
The UART clock is initialised to be as close to the requested
frequency as possible without exceeding it. Now that there is a
clock manager that returns the actual frequencies, an expected
48MHz clock is reported as
47999625. If the requested baudrate
== requested clock/16, there is no headroom and the slight
reduction in actual clock rate results in failure.
Detect cases where it looks like a "round" clock was chosen and
adjust the reported clock to match that "round" value. As the
code comment says:
/*
* If increasing a clock by less than 0.1% changes it
* from ..999.. to ..000.., round up.
*/
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Phil Elwell [Wed, 1 Mar 2017 16:06:53 +0000 (16:06 +0000)]
clk-bcm2835: Correct the prediv logic
If a clock has the prediv flag set, both the integer and fractional
parts must be scaled when calculating the resulting frequency.
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
Scott Ellis [Wed, 1 Mar 2017 12:22:24 +0000 (07:22 -0500)]
Add overlay for ads1115 ADCs (#1864)
Fe-Pi [Wed, 1 Mar 2017 11:42:43 +0000 (04:42 -0700)]
Add support for Fe-Pi audio sound card. (#1867)
Fe-Pi Audio Sound Card is based on NXP SGTL5000 codec.
Mechanical specification of the board is the same the Raspberry Pi Zero.
3.5mm jacks for Headphone/Mic, Line In, and Line Out.
Signed-off-by: Henry Kupis <fe-pi@cox.net>
Phil Elwell [Sun, 26 Feb 2017 01:13:02 +0000 (01:13 +0000)]
SQUASH: Add LOCO-V2 overlay from last commit