sparse port mapping.
Signed-off-by: Stefan Brüns
Acked-by: Maxime Ripard
---
Changes in v5:
- Rebase on slave-dma/next tree
Changes in v4:
- remove range checks for dma-channels/dma-requests DT properties
Changes in v3: None
Changes in v2:
- Set default number of dma-request if not provided
Commit f9cf3b2880cc ("platform/x86: hp-wmi: Refactor dock and tablet
state fetchers") consolidated the methods for docking and laptop mode
detection, but omitted to apply the correct mask for the laptop mode
(it always uses the constant for docking).
Signed-off-by: Stefan Brüns
---
T
The Lenovo Helix 2 and Dell XPS 12 (9Q33) have an extra button on the
front showing a 'Windows' logo, both reporting event codes 0xC2/0xC3
on press/release.
Tested on XPS 12, for info on the Helix 2 see:
https://www.spinics.net/lists/ibm-acpi-devel/msg03982.html
Signed-off-by: St
Event code 0xcc is emitted by several convertibles (Dell XPS 12 9Q33 BIOS
A8, Dell XPS 13 2in1 9365, HP Spectre x360, Lenovo Thinkpad Helix) when
entering tablet mode, and 0xcd on return to laptop mode.
Signed-off-by: Stefan Brüns
---
The changes where tested on an XPS 12 with BIOS version A8
The Rotate Lock button event is emitted on the XPS 12 (BIOS A8, but not
on BIOS A2).
Signed-off-by: Stefan Brüns
---
The changes where tested on an XPS 12 with BIOS version A8 (2015-03-03).
An earlier BIOS version (A2, ~2013) did not report the event, at least
not using the INT33D6 plattform
logo" button/key found on
the XPS 12 display (i.e. in tablet mode, it is the only key reachable).
The Lenovo Helix 2 has an equivalent touch button. The event currently
uses KEY_MENU, although a distinct key code may be a better choice.
Stefan Brüns (4):
Input: sparse-keymap - send sync
* events, but
it is required for the intel-vbtn platform driver to generate
SW_TABLET_MODE events.
Signed-off-by: Stefan Brüns
---
drivers/input/sparse-keymap.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/input/sparse-keymap.c b/drivers/input/sparse-keymap.c
index bb0349fa64bc
On Thursday, November 2, 2017 10:04:01 AM CET Maciej Purski wrote:
> On 10/14/2017 08:27 PM, Stefan Bruens wrote:
> > On Montag, 9. Oktober 2017 11:29:43 CEST Maciej Purski wrote:
> >> On 10/01/2017 09:48 PM, Stefan Brüns wrote:
> >>> According to the ABI documenta
While the config uses the physical value corresponding to the LSB
for both the power and the bus voltage register, the shunt voltage is
specified as parts of 1 mV. Use the LSB physical value for all registers.
No functional change.
Signed-off-by: Stefan Brüns
---
Changes in v2:
- new patch
, not bus voltage register
- Shift instead of masking the LSBs
- new patch
- Fix conversion for shunt gain, function expects milli, not micro
Stefan Brüns (3):
iio: adc: ina2xx: Shift bus voltage register to mask flag bits
iio: adc: ina2xx: Use LSB specifier instead of divider in config
iio
uniform API to
userspace.
As the gain settings are incorporated into the raw values by the sensor
itself, adjusting of the scale attributes is not necessary.
Signed-off-by: Stefan Brüns
---
Changes in v2:
- Fix conversion for shunt gain, function expects milli, not micro
drivers/iio/adc/ina2xx
Lower bits of the INA219/220 bus voltage register are conversion
status flags, properly shift the value.
When reading via IIO buffer, the value is passed on unaltered,
shifting is the responsibility of the user.
Signed-off-by: Stefan Brüns
---
Changes in v2:
- Apply to the shunt voltage, not
On Wednesday, 10 January 2018 00:33:37 CET Stefan Brüns wrote:
> In 2017-02, two drivers for the T230C where submitted, but until now
> only the one based on the older dvb-usb/cxusb.c driver has been part
> of the mainline kernel. As a dvb-usb-v2 driver is preferable, remove
> the
Commit f8585ce655e9cdeabc38e8e2580b05735110e4a5 ("[media] dvb-usb-cxusb:
Geniatech T230C support") sneaked in an unrelated change for the older
T230 (not C) model. As the commit was reverted this change was reverted
too, although likely correct.
Signed-off-by: Stefan Brüns
---
dri
From: Evgeny Plehov
This reverts commit f8585ce655e9cdeabc38e8e2580b05735110e4a5.
The T230C is handled by the dvb-usb-v2/dvbsky.c driver, which should
be preferred over a dvb-usb (v1) driver.
Signed-off-by: Stefan Brüns
---
drivers/media/usb/dvb-usb/cxusb.c | 139
. a correction of the RC model. As this change apparently is
correct, restore it. This has not been tested due to lack of hardware.
Evgeny Plehov (1):
Revert "[media] dvb-usb-cxusb: Geniatech T230C support"
Stefan Brüns (1):
[media] cxusb: restore RC_MAP for MyGica T230
drivers/med
SCALE.
I would prefer an early "return -EINVAL" here, as it matches better with the
other "switch (mask)" cases above.
Kind regards,
Stefan
--
Stefan Brüns / Bergstraße 21 / 52062 Aachen
home: +49 241 53809034 mobile: +49 151 50412019
signature.asc
Description: This is a digitally signed message part.
128 264346742 drivers/iio/adc/ina2xx-adc.o
>
> (gcc 8.2, x86-64)
>
> Detected by CoverityScan, CID#1462408 ("Missing break in switch")
>
> ---
>
> V2: use returns instead of break statements to keep with the
> current style used in the switch statement.
&g
I, but it also affects
the MyGica T230C. As all supported devices structure the registration/
unregistration identically, apply the change for all device types.
Signed-off-by: Stefan Brüns
---
drivers/media/usb/dvb-usb-v2/dvbsky.c | 18 ++
1 file changed, 10 insertions(+), 8 deletion
All error cases inside the function already report errors via dev_err(),
and dvb_usb_v2_generic_rw also reports all error cases, so there is
no silent code path when an error has occured.
Signed-off-by: Stefan Brüns
---
drivers/media/usb/dvb-usb-v2/af9035.c | 2 --
1 file changed, 2 deletions
Errors are already reported by the common code in dvb_usb_v2_generic_io
(which dvbsky_usb_generic_rw is a wrapper of), so there is no reason
report the error again.
Signed-off-by: Stefan Brüns
---
drivers/media/usb/dvb-usb-v2/dvbsky.c | 11 ---
1 file changed, 11 deletions(-)
diff
ret is returned. Skip setting ret and return
immediately (no cleanup necessary).
Signed-off-by: Stefan Brüns
---
drivers/media/usb/dvb-usb-v2/dvb_usb_urb.c | 15 ++-
1 file changed, 10 insertions(+), 5 deletions(-)
diff --git a/drivers/media/usb/dvb-usb-v2/dvb_usb_urb.c
b/drivers
and af9035.
v2: Add Signed-off-by
Stefan Brüns (3):
media: dvb-usb-v2: Report error on all error paths
media: dvbsky: Remove duplicate error reporting for
dvbsky_usb_generic_rw
media: af9035: Remove duplicate error reporting for
dvbsky_usb_generic_rw
drivers/media/usb/dvb-usb-v
The required command sequence for the new tuner (Si2141) was traced from the
current Windows driver and verified with a small python script/libusb.
The changes to the Si2168 and dvbsky driver are mostly additions of the
required IDs and some glue code.
Stefan Brüns (3):
[media] si2157: Add
Mygica T230 DVB-T/T2/C USB stick support. It uses the same FX2/Si2168
bridge/demodulator combo as the other devices supported by the driver,
but uses the Si2141 tuner.
Several DVB-T (MPEG2) and DVB-T2 (H.265) channels were tested, as well as
the include remote control.
Signed-off-by: Stefan Brüns
Add handling for new revision, requiring new firmware.
Signed-off-by: Stefan Brüns
---
drivers/media/dvb-frontends/si2168.c | 4
drivers/media/dvb-frontends/si2168_priv.h | 2 ++
2 files changed, 6 insertions(+)
diff --git a/drivers/media/dvb-frontends/si2168.c
b/drivers/media/dvb
The Si2141 needs two distinct commands for powerup/reset, otherwise it
will not respond to chip revision requests. It also needs a firmware
to run properly.
Signed-off-by: Stefan Brüns
---
drivers/media/tuners/si2157.c | 23 +--
drivers/media/tuners/si2157_priv.h | 2
The Si2141 needs two distinct commands for powerup/reset, otherwise it
will not respond to chip revision requests. It also needs a firmware
to run properly.
Signed-off-by: Stefan Brüns
---
drivers/media/tuners/si2157.c | 23 +--
drivers/media/tuners/si2157_priv.h | 2
Add handling for new revision, requiring new firmware.
Signed-off-by: Stefan Brüns
---
drivers/media/dvb-frontends/si2168.c | 4
drivers/media/dvb-frontends/si2168_priv.h | 2 ++
2 files changed, 6 insertions(+)
diff --git a/drivers/media/dvb-frontends/si2168.c
b/drivers/media/dvb
Mygica T230 DVB-T/T2/C USB stick support. It uses the same FX2/Si2168
bridge/demodulator combo as the other devices supported by the driver,
but uses the Si2141 tuner.
Several DVB-T (MPEG2) and DVB-T2 (H.265) channels were tested, as well as
the included remote control.
Signed-off-by: Stefan
The required command sequence for the new tuner (Si2141) was traced from the
current Windows driver and verified with a small python script/libusb.
The changes to the Si2168 and dvbsky driver are mostly additions of the
required IDs and some glue code.
Stefan Brüns (3):
[media] si2157: Add
The buffer allocation for the firmware data was changed in
commit 43fab9793c1f ("dvb-usb: don't use stack for firmware load"),
but the same applies for the reset value.
Signed-off-by: Stefan Brüns
---
This patch replaces the earlier submission conflicting with commit
43fab9793c
The Si2141 needs two distinct commands for powerup/reset, otherwise it
will not respond to chip revision requests. It also needs a firmware
to run properly.
Signed-off-by: Stefan Brüns
---
drivers/media/tuners/si2157.c | 23 +--
drivers/media/tuners/si2157_priv.h | 2
Mygica T230 DVB-T/T2/C USB stick support. It uses the same FX2/Si2168
bridge/demodulator combo as the T230, but uses the Si2141 tuner.
Factor out the common code and pass the tuner type and if port as
parameter, to avoid duplicating the initialization code.
Signed-off-by: Stefan Brüns
The required command sequence for the new tuner (Si2141) was traced from the
current Windows driver and verified with a small python script/libusb.
The changes to the Si2168 and cxusb driver are mostly addition of the
required IDs and some glue code.
Stefan Brüns (3):
[media] si2157: Add
Add handling for new revision, requiring new firmware.
Signed-off-by: Stefan Brüns
---
drivers/media/dvb-frontends/si2168.c | 4
drivers/media/dvb-frontends/si2168_priv.h | 2 ++
2 files changed, 6 insertions(+)
diff --git a/drivers/media/dvb-frontends/si2168.c
b/drivers/media/dvb
When the context is deactivated, the link_type is set to 0xff, which
triggers a warning message, and results in a wrong link status, as
the LSI is ignored.
Signed-off-by: Stefan Brüns
---
drivers/net/usb/sierra_net.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff
, APN internet.telekom, IPv4v6 PDP type.
Stefan Brüns (2):
sierra_net: Add support for IPv6 and Dual-Stack Link Sense Indications
sierra_net: Skip validating irrelevant fields for IDLE LSIs
drivers/net/usb/sierra_net.c | 92 ++--
1 file changed, 63
erent link type.
Signed-off-by: Stefan Brüns
---
Example LSI LINK UP indication:
00 ed 78 00 04 01 00 e9 0a 14 00 54 00 65 00 6c ..xT.e.l
0010 00 65 00 6b 00 6f 00 6d 00 2e 00 64 00 65 48 03 .e.k.o.m...d.eH.
0020 c8 be d1 00 62 00 00 00 2c 80 f0 01 00 00 00 00 b...,...
When the context is deactivated, the link_type is set to 0xff, which
triggers a warning message, and results in a wrong link status, as
the LSI is ignored.
Signed-off-by: Stefan Brüns
---
drivers/net/usb/sierra_net.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff
erent link type.
Signed-off-by: Stefan Brüns
---
v2: Do not overwrite protocol field in rx_fixup
Example LSI LINK UP indication:
00 ed 78 00 04 01 00 e9 0a 14 00 54 00 65 00 6c ..xT.e.l
0010 00 65 00 6b 00 6f 00 6d 00 2e 00 64 00 65 48 03 .e.k.o.m...d.eH.
0020 c8 be d1 00 62 0
, APN internet.telekom, IPv4v6 PDP type. Both
IPv4 and IPv6 connections work.
v2: Do not overwrite protocol field in rx_fixup
Stefan Brüns (2):
sierra_net: Add support for IPv6 and Dual-Stack Link Sense Indications
sierra_net: Skip validating irrelevant fields for IDLE LSIs
drivers/net/usb
, APN internet.telekom, IPv4v6 PDP type. Both
IPv4 and IPv6 connections work.
v2: Do not overwrite protocol field in rx_fixup
v3: Remove leftover struct ethhdr *eth declaration
Stefan Brüns (2):
sierra_net: Add support for IPv6 and Dual-Stack Link Sense Indications
sierra_net: Skip validating
erent link type.
Signed-off-by: Stefan Brüns
---
v2: Do not overwrite protocol field in rx_fixup
v3: Remove leftover struct ethhdr *eth declaration
Example LSI LINK UP indication:
00 ed 78 00 04 01 00 e9 0a 14 00 54 00 65 00 6c ..xT.e.l
0010 00 65 00 6b 00 6f 00 6d 00 2e 00 64 0
When the context is deactivated, the link_type is set to 0xff, which
triggers a warning message, and results in a wrong link status, as
the LSI is ignored.
Signed-off-by: Stefan Brüns
---
drivers/net/usb/sierra_net.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff
f 0 by itself, avoid calling
it using the dvb_usb_generic_read wrapper function.
Signed-off-by: Stefan Brüns
---
drivers/media/usb/dvb-usb/cxusb.c | 15 ---
1 file changed, 8 insertions(+), 7 deletions(-)
diff --git a/drivers/media/usb/dvb-usb/cxusb.c
b/drivers/media/usb/dvb-usb/cxusb.
The USB control messages require DMA to work. We cannot pass
a stack-allocated buffer, as it is not warranted that the
stack would be into a DMA enabled area.
Signed-off-by: Stefan Brüns
---
drivers/media/usb/dvb-usb/dvb-usb-firmware.c | 30
1 file changed, 17
sets the config register accordingly.
Stefan Brüns (2):
iio: adc: Fix integration time/averaging for INA219/220
iio: adc: Allow setting Shunt Voltage PGA gain and Bus Voltage range
drivers/iio/adc/ina2xx-adc.c | 344 ---
1 file changed, 322 insertions
Reducing shunt and bus voltage range improves the accuracy, so allow
altering the default settings.
Signed-off-by: Stefan Brüns
---
drivers/iio/adc/ina2xx-adc.c | 165 ++-
1 file changed, 164 insertions(+), 1 deletion(-)
diff --git a/drivers/iio/adc
INA219.
Signed-off-by: Stefan Brüns
---
drivers/iio/adc/ina2xx-adc.c | 179 ++-
1 file changed, 158 insertions(+), 21 deletions(-)
diff --git a/drivers/iio/adc/ina2xx-adc.c b/drivers/iio/adc/ina2xx-adc.c
index 3263231276ca..d1678f886297 100644
--- a/drivers
INA219.
Signed-off-by: Stefan Brüns
---
drivers/iio/adc/ina2xx-adc.c | 204 ++-
1 file changed, 182 insertions(+), 22 deletions(-)
diff --git a/drivers/iio/adc/ina2xx-adc.c b/drivers/iio/adc/ina2xx-adc.c
index bba10a1b2fcb..232c0b80d658 100644
--- a/drivers
Flags for shared channel attributes should be set on all channels of a
channel set. I.e. SAMP_FREQUENCY and OVERSAMPLING_RATIO are set on the
in_voltage{0,1} channels, thus should be set on in_power, in_current.
Signed-off-by: Stefan Brüns
---
drivers/iio/adc/ina2xx-adc.c | 2 ++
1 file changed
While the INA226 has a conversion ready flag (CVRF) in the R/W Mask/Enable
register with read-to-clear semantics, the corresponding bit of the INA219
(CNVR) is part of the bus voltage register. The flag is cleared by reading
the power register.
Signed-off-by: Stefan Brüns
---
drivers/iio/adc
/
averaging from INA219/220
- changed Patch v1 1/2 (now 2/3, feedback by Jonathan Cameron):
* Use correct flags for all channels/chips
* Improve readability of chip/channel handling in if statement
- dropped Patch v1 2/2 for now
- added Patch v2 3/3
Stefan Brüns (3):
iio: adc: ina2xx
Commit c43a102e67db ("iio: ina2xx: add support for TI INA2xx Power Monitors")
introduced the in_powerY_raw attribute, but omitted the corresponding
documentation.
The description is correct for the INA2xx and the MAX9611 IIO drivers.
Signed-off-by: Stefan Brüns
---
Documentation/A
The ina2xx driver appeared in the Linux kernel version 4.5, but provided
no documentation. Contrary to other uses of resistance in IIO, ina2xx uses
microohms instead of ohms in the sysfs attribute.
Signed-off-by: Stefan Brüns
---
Documentation/ABI/testing/sysfs-bus-iio-adc-ina2xx-adc | 7
use of ohms for resistance in IIO, thus is added as
ina2xx specific documentation.
Stefan Brüns (2):
iio: Documentation: Add missing documentation for power attribute
iio: Documentation: Add ina2xx shunt_resistor attribute documentation
Documentation/ABI/testing/sysfs-bus-iio| 9
iteration. In case
the conversion overrruns the register readout (i.e. fast sampling combined
with a slow bus), one or multiple samples will be dropped.
Signed-off-by: Stefan Brüns
---
Changes in v3:
- use s64_div for 64 bit integer division to fix compiles on 32 bit archs
Changes in v2:
- add a
the center.
Fallback to bitbanging is already done for the CRT connector.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=92685
Signed-off-by: Stefan Brüns
---
Changes in v2:
- Fix/enhance commit message, no code changes
drivers/gpu/drm/i915/intel_hdmi.c | 14 +++---
1 file c
iteration. In case
the conversion overrruns the register readout (i.e. fast sampling combined
with a slow bus), one or multiple samples will be dropped.
Signed-off-by: Stefan Brüns
---
Changes in v4:
- Typo, div_s64, not s64_div
Changes in v3:
- use s64_div for 64 bit integer division to fix
iio_push_to_buffers_with_timestamp expects a void pointer, so the cast
is both unnecessary and misleading.
Signed-off-by: Stefan Brüns
---
Changes in v2: None
drivers/iio/adc/ina2xx-adc.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/iio/adc/ina2xx-adc.c b
schedule it one interval after the
flag bit has been set.
Split the work function in two functions, one for the status poll and one
for reading the values, to be able to note down the time when the flag
bit is raised.
Signed-off-by: Stefan Brüns
---
Changes in v2:
- Describe old behaviour in
The conversion time can be up to 16 seconds (8 ms per channel, 2 channels,
1024 times averaging).
Signed-off-by: Stefan Brüns
---
Changes in v2: None
drivers/iio/adc/ina2xx-adc.c | 8 +---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/iio/adc/ina2xx-adc.c b/drivers
As the timestamp is no longer (ab-)used to measure the function run time,
it can be taken at the correct time, i.e. when the conversion has finished.
Signed-off-by: Stefan Brüns
---
Changes in v2: None
drivers/iio/adc/ina2xx-adc.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions
iteration. In case
the conversion overrruns the register readout (i.e. fast sampling combined
with a slow bus), one or multiple samples will be dropped.
Signed-off-by: Stefan Brüns
---
Changes in v2:
- add a comment mentioning skipping samples on overrun
drivers/iio/adc/ina2xx-adc.c | 41
The timestamp is inserted into the buffer after the sample data by
iio_push_to_buffers_with_timestamp, document the space requirement for
the timestamp.
Signed-off-by: Stefan Brüns
---
Changes in v2: None
drivers/iio/adc/ina2xx-adc.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion
t sampling intervals inbetween.
Changes in v2:
- add a comment mentioning skipping samples on overrun
- Describe old behaviour in commit message more clearly
No real code changes, but added a comment in patch 5, and clarified
commit messages of patch 5 and 7.
Stefan Brüns (7):
iio: adc: ina2xx: Re
/2378282
Signed-off-by: Stefan Brüns
---
Changes in v2: None
drivers/iio/adc/ina2xx-adc.c | 14 --
1 file changed, 14 deletions(-)
diff --git a/drivers/iio/adc/ina2xx-adc.c b/drivers/iio/adc/ina2xx-adc.c
index 8c8120406f52..b027d485398b 100644
--- a/drivers/iio/adc/ina2xx-adc.c
+++ b
the center.
Fallback to bitbanging is already done for the CRT connector.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=92685
Signed-off-by: Stefan Brüns
---
drivers/gpu/drm/i915/intel_hdmi.c | 14 +++---
1 file changed, 11 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm
On Wednesday, January 3, 2018 8:14:47 AM CET Jani Nikula wrote:
> On Tue, 02 Jan 2018, Chris Wilson wrote:
> > Quoting Rodrigo Vivi (2018-01-02 19:12:18)
> >
> >> On Sun, Dec 31, 2017 at 10:34:54PM +, Stefan Brüns wrote:
> >> > +
resistor value is just
stored.
> static int set_shunt_resistor(struct ina2xx_chip_info *chip, unsigned int
> val) {
> - if (val <= 0 || val > chip->config->calibration_factor)
> + if (val == 0 || val > INT_MAX)
> return -EINVAL;
>
>
> Power_lsb value should also follow shunt_resistor changes as stated in
> datasheet:
> power_lsb = 25 * current_lsb (ina 226)
> power_lsb = 20 * current_lsb (ina 219)
>
> This is a part of the patchset: https://lkml.org/lkml/2017/11/22/394
>
> Signed-off-by: Maciej Pursk
On Tuesday, December 12, 2017 9:15:30 PM CET Jonathan Cameron wrote:
> On Sun, 10 Dec 2017 21:53:42 +0100
>
> Stefan Brüns wrote:
> > On Sunday, December 10, 2017 6:27:33 PM CET Jonathan Cameron wrote:
> > > On Fri, 8 Dec 2017 18:41:48 +0100
> > >
> > >
eMMC controller, as the MISO pin is
also used for the HS400 eMMC data strobe. This is only a concern if the board
uses eMMC (does not apply to the Pine64) *and* is using HS400 mode. The same
pin conflict exists for the H5.
Stefan Brüns (2):
arm64: allwinner: a64: add SPI nodes
arm64: allwinner
The A64 SPI controllers are register compatible to the h3/h5 SPI
controllers.
The A64 has two SPI controllers, each with a single chip select.
The handles for the DMA channels (23/24 for SPI0/SPI1) are omitted,
as the A64 DMA controller node is currently missing.
Signed-off-by: Stefan Brüns
The two spi channels/controllers are available on the PI-2 resp. Euler
connector, enable both. Contrary to the Pi, the A64 SOC only supports
one chip select, so the second chipselect is not available (though
it can be emulated using gpio chipselect).
Signed-off-by: Stefan Brüns
---
arch/arm64
The A64 SPI controllers are register compatible to the h3/h5 SPI
controllers.
The A64 has two SPI controllers, each with a single chip select.
The handles for the DMA channels (23/24 for SPI0/SPI1) are omitted,
as the A64 DMA support is currently missing.
Signed-off-by: Stefan Brüns
---
v2
The A64 SoC has a DMA controller that supports 8 DMA channels
to and from various peripherals.
Add a device node for it.
Signed-off-by: Stefan Brüns
---
Documentation/devicetree/bindings/dma/sun6i-dma.txt | 1 +
arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 9 +
2 files changed
and the driver.
Stefan Brüns (3):
dmaengine: sun6i: Correct DMA support on H3
arm64: allwinner: a64: Add device node for DMA controller
dmaengine: sun6i: Add support for Allwinner A64
.../devicetree/bindings/dma/sun6i-dma.txt | 1 +
arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi
The A64 SoC has the same dma engine as the H3 (sun8i), with a
reduced amount of physical channels. Add the proper config data
and compatible string to support it.
Signed-off-by: Stefan Brüns
---
arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 4
drivers/dma/sun6i-dma.c
added to the config.
Separating verification of the config and conversion to register values
allows to keep both independent of the used controller.
Signed-off-by: Stefan Brüns
---
drivers/dma/sun6i-dma.c | 128 +---
1 file changed, 88 insertions(+), 40
layout defined maximum
of 32 is used.
Signed-off-by: Stefan Brüns
---
.../devicetree/bindings/dma/sun6i-dma.txt | 26 ++
1 file changed, 26 insertions(+)
diff --git a/Documentation/devicetree/bindings/dma/sun6i-dma.txt
b/Documentation/devicetree/bindings/dma/sun6i
The A64 SoC has the same dma engine as the H3 (sun8i), with a
reduced amount of physical channels. To allow future reuse of the
compatible, leave the channel count etc. in the config data blank
and retrieve it from the devicetree.
Signed-off-by: Stefan Brüns
---
drivers/dma/sun6i-dma.c | 23
sparse port mapping.
Signed-off-by: Stefan Brüns
---
drivers/dma/sun6i-dma.c | 37 -
1 file changed, 36 insertions(+), 1 deletion(-)
diff --git a/drivers/dma/sun6i-dma.c b/drivers/dma/sun6i-dma.c
index 245a147f718f..b5ecc97a0d5a 100644
--- a/drivers/dma/sun6i
The spi controller nodes omit the dma controller/channel references, add
it.
This does not yet enable DMA for SPI transfers, as the spi-sun6i driver
lacks support for DMA, but always uses PIO to the FIFO.
Signed-off-by: Stefan Brüns
---
arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 4
1
Preparatory patch: If the same compatible is used for different SoCs which
have a common register layout, but different number of channels, the
channel count can no longer be stored in the config. Store it in the
device structure instead.
Signed-off-by: Stefan Brüns
---
drivers/dma/sun6i-dma.c
it in the controller config structure.
Signed-off-by: Stefan Brüns
---
drivers/dma/sun6i-dma.c | 31 ++-
1 file changed, 26 insertions(+), 5 deletions(-)
diff --git a/drivers/dma/sun6i-dma.c b/drivers/dma/sun6i-dma.c
index bcd496edc70f..45bcd5271d94 100644
--- a
The A64 SoC has a DMA controller that supports 8 DMA channels
to and from various peripherals. The last used DRQ port is 27.
Add a device node for it.
Signed-off-by: Stefan Brüns
---
arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 11 +++
1 file changed, 11 insertions(+)
diff --git a
: Stefan Brüns
---
drivers/dma/sun6i-dma.c | 36 +++-
1 file changed, 27 insertions(+), 9 deletions(-)
diff --git a/drivers/dma/sun6i-dma.c b/drivers/dma/sun6i-dma.c
index 45bcd5271d94..a6fc066a0ac6 100644
--- a/drivers/dma/sun6i-dma.c
+++ b/drivers/dma/sun6i-dma.c
The H3 supports bursts lengths of 1, 4, 8 and 16 transfers, each with
a width of 1, 2, 4 or 8 bytes.
The register value for the the width is log2-encoded, change the
conversion function to provide the correct value for width == 8.
Signed-off-by: Stefan Brüns
---
drivers/dma/sun6i-dma.c | 54
ovided in config or devicetree
Stefan Brüns (10):
dmaengine: sun6i: Correct setting of clock autogating register for
A83T/H3
dmaengine: sun6i: Correct burst length field offsets for H3
dmaengine: sun6i: Restructure code to allow extension for new SoCs
dmaengine: sun6i: Enable additio
out of the
conversion to distinct operations.
Signed-off-by: Stefan Brüns
---
drivers/dma/sun6i-dma.c | 66 -
1 file changed, 38 insertions(+), 28 deletions(-)
diff --git a/drivers/dma/sun6i-dma.c b/drivers/dma/sun6i-dma.c
index a6fc066a0ac6
The driver would happily accept buswidth of 16/32/64 bytes and program
garbage to its registers.
Signed-off-by: Stefan Brüns
---
drivers/dma/edma.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/dma/edma.c b/drivers/dma/edma.c
index 3879f80a4815..c944ea339425
BIT(), not BIT(log2), as it must be able
to encode a width of 3 bytes.
The corollary is, it is not possible to encode either a width of 32 or
64 bytes, as the field has a size of 32 bits, and only a subset of the
controller capabilities can be exposed.
Signed-off-by: Stefan Brüns
---
drivers/dma
Instead of reading the value from the register on each query, store the
set value.
Signed-off-by: Stefan Brüns
---
drivers/iio/light/vl6180.c | 13 -
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/drivers/iio/light/vl6180.c b/drivers/iio/light/vl6180.c
index
Instead of manually iterating the array of allowed gain values, use
find_closest. Storing the current gain setting avoids accessing the
hardware on each query.
Signed-off-by: Stefan Brüns
---
drivers/iio/light/vl6180.c | 85 --
1 file changed, 44
The reported scale was only correct for the default settings of 100 ms
integration time and gain 1.
This aligns the reported scale with the behaviour of any other IIO driver
and the documented ABI, but may require userspace changes if someone uses
non-default settings.
Signed-off-by: Stefan
This improves code uniformity (range checks for als_gain are also done
in the setter). Also unmangle rounding and calculation of register value.
The calculated integration time it_ms is required in the next patch of
the series.
Signed-off-by: Stefan Brüns
---
drivers/iio/light/vl6180.c | 18
register values. Use the saved values
to report the correct scale value.
Stefan Brüns (4):
iio: light: vl6180: Move range check to integration time setter,
cleanup
iio: light: vl6180: Avoid readback of integration time register
iio: light: vl6180: Cleanup als_gain lookup, avoid register readback
Commit 93c6ee94c140 ("dma: Support for 3 bytes word size") and
commit 534a729866f9 ("dmaengine: Add 16 bytes, 32 bytes and 64 bytes
bus widths") added additional values for the allowed word size, but
omitted these from the struct dma_slave_config documentation.
Signed-
1 - 100 of 188 matches
Mail list logo