[PATCH v2 1/2] pinctrl: mcp23s08: Fix mcp23x17_regmap initialiser

2020-08-28 Thread Thomas Preston
The mcp23x17_regmap is initialised with structs named "mcp23x16". However, the mcp23s08 driver doesn't support the MCP23016 device yet, so this appears to be a typo. Fixes: 8f38910ba4f6 ("pinctrl: mcp23s08: switch to regmap caching") Signed-off-by: Thomas Preston ---

[PATCH v2 0/2] pinctrl: mcp23s08: Fixups for mcp23x17

2020-08-28 Thread Thomas Preston
t; 1) + 1` changes because the regmap handles GPIOB 0x13 with `.val_bits = 16`. - Dropped the interrupt-controller changes. Thanks again, Thomas Thomas Preston (2): pinctrl: mcp23s08: Fix mcp23x17_regmap initialiser pinctrl: mcp23s08: Fix mcp23x17 precious range drivers/pinct

[PATCH v2 2/2] pinctrl: mcp23s08: Fix mcp23x17 precious range

2020-08-28 Thread Thomas Preston
p.com/downloads/en/DeviceDoc/20001952C.pdf Fixes: 8f38910ba4f6 ("pinctrl: mcp23s08: switch to regmap caching") Signed-off-by: Thomas Preston --- drivers/pinctrl/pinctrl-mcp23s08.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/pinctrl/pinctrl-mcp23s08.c

Re: [PATCH 1/3] pinctrl: mcp23s08: Fixup mcp23x17 regmap_config

2020-08-28 Thread Thomas Preston
Hey Andy, Linus, Thanks for looking at this. On 28/08/2020 11:09, Andy Shevchenko wrote: On Fri, Aug 14, 2020 at 1:35 PM Thomas Preston wrote: - Fix a typo where mcp23x17 configs are referred to as mcp23x16. I'm not sure it's correct. MPC23016 is an existing I²C IO expand

Re: [PATCH 1/3] pinctrl: mcp23s08: Fixup mcp23x17 regmap_config

2020-08-28 Thread Thomas Preston
On 28/08/2020 10:28, Andy Shevchenko wrote: On Fri, Aug 28, 2020 at 11:06:21AM +0200, Linus Walleij wrote: On Fri, Aug 14, 2020 at 12:04 PM Thomas Preston wrote: - Fix a typo where mcp23x17 configs are referred to as mcp23x16. - Fix precious range to include INTCAP{A,B}, which clear on read

Re: [PATCH 0/3] pinctrl: mcp23s08: Fixups for mcp23x17

2020-08-18 Thread Thomas Preston
On 17/08/2020 20:29, Rob Herring wrote: On Fri, Aug 14, 2020 at 02:56:54PM +0100, Thomas Preston wrote: Actually I think I'm wrong about the interrupt-controller changes in patches 0002 and 0003. You are. Looking at the datasheet, the GPIOs have interrupt capability. GPIO controller

Re: [PATCH 0/3] pinctrl: mcp23s08: Fixups for mcp23x17

2020-08-14 Thread Thomas Preston
On 14/08/2020 11:03, Thomas Preston wrote: I'm in the process of adding a device tree overlay for the PiFace Digital Raspberry Pi daughter board [0]. It's an mcp23s17 SPI GPIO port expander. In doing so, I noticed some errors with the mcp23s08 driver. [snip] They're quite trivia

[PATCH 1/3] pinctrl: mcp23s08: Fixup mcp23x17 regmap_config

2020-08-14 Thread Thomas Preston
gpiochip2 {0..15}`. Signed-off-by: Thomas Preston --- drivers/pinctrl/pinctrl-mcp23s08.c | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/drivers/pinctrl/pinctrl-mcp23s08.c b/drivers/pinctrl/pinctrl-mcp23s08.c index 42b12ea14d6b..0138638276e7

[PATCH 0/3] pinctrl: mcp23s08: Fixups for mcp23x17

2020-08-14 Thread Thomas Preston
spberrypi/linux/pull/3794 Thomas Preston (3): pinctrl: mcp23s08: Fixup mcp23x17 regmap_config pinctrl: mcp23s08: Remove interrupt-controller devicetree: mcp23s08: Remove interrupt-controller .../bindings/pinctrl/pinctrl-mcp23s08.txt | 8 - drivers/pinctrl/pinctrl-m

[PATCH 3/3] devicetree: mcp23s08: Remove interrupt-controller

2020-08-14 Thread Thomas Preston
ot; properties from the pinctrl-mcp23s08 devicetree bindings documentation. [0] Documentation/devicetree/bindings/interrupt-controller/interrupts.txt Signed-off-by: Thomas Preston --- .../devicetree/bindings/pinctrl/pinctrl-mcp23s08.txt | 8 1 file changed, 8 deletions(-) diff --git a/D

[PATCH 2/3] pinctrl: mcp23s08: Remove interrupt-controller

2020-08-14 Thread Thomas Preston
always present if we want interrupts enabled. [0] Documentation/devicetree/bindings/interrupt-controller/interrupts.txt Signed-off-by: Thomas Preston --- drivers/pinctrl/pinctrl-mcp23s08.c | 7 +++ drivers/pinctrl/pinctrl-mcp23s08.h | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-)

Re: [alsa-devel] [PATCH v2 3/3] ASoC: TDA7802: Add turn-on diagnostic routine

2019-08-02 Thread Thomas Preston
On 02/08/2019 12:10, Mark Brown wrote: > On Fri, Aug 02, 2019 at 09:32:17AM +0100, Thomas Preston wrote: >> On 02/08/2019 00:42, Mark Brown wrote: > >>> Yes, that's definitely doable - we've got some other drivers with >>> similar things like calibrat

Re: [alsa-devel] [PATCH v2 3/3] ASoC: TDA7802: Add turn-on diagnostic routine

2019-08-02 Thread Thomas Preston
On 02/08/2019 00:42, Mark Brown wrote: > On Tue, Jul 30, 2019 at 05:28:11PM +0100, Thomas Preston wrote: >> On 30/07/2019 16:50, Mark Brown wrote: > >>> Like I say it's not just debugfs though, there's the standard driver >>> interface too. > >>

Re: [alsa-devel] [PATCH v2 2/3] ASoC: Add codec driver for ST TDA7802

2019-07-31 Thread Thomas Preston
On 31/07/2019 07:06, Marco Felsch wrote: > Hi Thomas, > > again sorry for jumping in.. > Np! > On 19-07-30 18:26, Thomas Preston wrote: >> On 30/07/2019 15:58, Mark Brown wrote: >>> On Tue, Jul 30, 2019 at 01:09:36PM +0100, Thomas Preston wrote: >

Re: [alsa-devel] [PATCH v2 2/3] ASoC: Add codec driver for ST TDA7802

2019-07-30 Thread Thomas Preston
On 30/07/2019 15:58, Mark Brown wrote: > On Tue, Jul 30, 2019 at 01:09:36PM +0100, Thomas Preston wrote: > >> index ..0f82a88bc1a4 >> --- /dev/null >> +++ b/sound/soc/codecs/tda7802.c >> @@ -0,0 +1,509 @@ >> +// SPDX-License-Identifier: GPL-2.

Re: [alsa-devel] [PATCH v2 3/3] ASoC: TDA7802: Add turn-on diagnostic routine

2019-07-30 Thread Thomas Preston
On 30/07/2019 16:50, Mark Brown wrote: > On Tue, Jul 30, 2019 at 04:25:56PM +0100, Thomas Preston wrote: >> On 30/07/2019 15:19, Mark Brown wrote: > >>> It is unclear what this mutex usefully protects, it only gets taken when >>> writing to the debugfs file to tr

Re: [alsa-devel] [PATCH v2 2/3] ASoC: Add codec driver for ST TDA7802

2019-07-30 Thread Thomas Preston
On 30/07/2019 13:38, Charles Keepax wrote: > On Tue, Jul 30, 2019 at 01:09:36PM +0100, Thomas Preston wrote: >> Add an I2C based codec driver for ST TDA7802 amplifier. The amplifier >> supports 4 audio channels but can support up to 16 with multiple >> devices. >> >&

Re: [alsa-devel] [PATCH v2 3/3] ASoC: TDA7802: Add turn-on diagnostic routine

2019-07-30 Thread Thomas Preston
On 30/07/2019 15:20, Mark Brown wrote: > On Tue, Jul 30, 2019 at 03:04:19PM +0100, Thomas Preston wrote: >> On 30/07/2019 13:41, Charles Keepax wrote: > >>> This could probably be removed using regmap_multi_reg_write. > >> The problem is that I want to retain the st

Re: [alsa-devel] [PATCH v2 3/3] ASoC: TDA7802: Add turn-on diagnostic routine

2019-07-30 Thread Thomas Preston
On 30/07/2019 15:19, Mark Brown wrote: > On Tue, Jul 30, 2019 at 01:09:37PM +0100, Thomas Preston wrote: > >> +struct dentry *debugfs; >> +struct mutex diagnostic_mutex; >> +}; > > It is unclear what this mutex usefully protects, it only gets taken when &g

Re: [alsa-devel] [PATCH v2 1/3] dt-bindings: ASoC: Add TDA7802 amplifier

2019-07-30 Thread Thomas Preston
On 30/07/2019 14:12, Marco Felsch wrote: > Hi Charles, > > sorry for jumping in.. > > On 19-07-30 13:27, Charles Keepax wrote: >> On Tue, Jul 30, 2019 at 01:09:35PM +0100, Thomas Preston wrote: >>> Signed-off-by: Thomas Preston >>> Cc: Patrick Glaser

Re: [alsa-devel] [PATCH v2 1/3] dt-bindings: ASoC: Add TDA7802 amplifier

2019-07-30 Thread Thomas Preston
On 30/07/2019 13:27, Charles Keepax wrote: > On Tue, Jul 30, 2019 at 01:09:35PM +0100, Thomas Preston wrote: >> Signed-off-by: Thomas Preston >> Cc: Patrick Glaser >> Cc: Rob Duncan >> Cc: Nate Case >> --- >> .../devicetree/bindings/sound/tda7802.txt

Re: [alsa-devel] [PATCH v2 3/3] ASoC: TDA7802: Add turn-on diagnostic routine

2019-07-30 Thread Thomas Preston
Hi, Thanks for getting back to me so quickly. On 30/07/2019 13:41, Charles Keepax wrote: > On Tue, Jul 30, 2019 at 01:09:37PM +0100, Thomas Preston wrote: >> Add a debugfs device node which initiates the turn-on diagnostic routine >> feature of the TDA7802 amplifier. The four s

[PATCH v2 3/3] ASoC: TDA7802: Add turn-on diagnostic routine

2019-07-30 Thread Thomas Preston
Add a debugfs device node which initiates the turn-on diagnostic routine feature of the TDA7802 amplifier. The four status registers (one per channel) are returned. Signed-off-by: Thomas Preston --- Changes since v1: - Rename speaker-test to (turn-on) diagnostics - Move turn-on diagnostic to

[PATCH v2 2/3] ASoC: Add codec driver for ST TDA7802

2019-07-30 Thread Thomas Preston
Add an I2C based codec driver for ST TDA7802 amplifier. The amplifier supports 4 audio channels but can support up to 16 with multiple devices. Signed-off-by: Thomas Preston Cc: Patrick Glaser Cc: Rob Duncan Cc: Nate Case --- Changes since v1: - Use ALSA kcontrol interface to expose device

[PATCH v2 1/3] dt-bindings: ASoC: Add TDA7802 amplifier

2019-07-30 Thread Thomas Preston
Signed-off-by: Thomas Preston Cc: Patrick Glaser Cc: Rob Duncan Cc: Nate Case --- .../devicetree/bindings/sound/tda7802.txt | 26 +++ 1 file changed, 26 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/tda7802.txt diff --git a/Documentation

[PATCH v2 0/3] ASoC: Codecs: Add TDA7802 codec

2019-07-30 Thread Thomas Preston
there's anything else which needs changing. Many thanks, Thomas Thomas Preston (3): dt-bindings: ASoC: Add TDA7802 amplifier ASoC: Add codec driver for ST TDA7802 ASoC: TDA7802: Add turn-on diagnostic routine .../devicetree/bindings/sound/tda7802.txt | 26 + sound/soc/codecs/Kc

[PATCH v1 1/4] dt-bindings: ASoC: Add TDA7802 amplifier

2019-06-11 Thread Thomas Preston
Signed-off-by: Thomas Preston Cc: Patrick Glaser Cc: Rob Duncan Cc: Nate Case --- .../devicetree/bindings/sound/tda7802.txt | 26 ++ 1 file changed, 26 insertions(+) create mode 100644 Documentation/devicetree/bindings/sound/tda7802.txt diff --git a

[PATCH v1 4/4] ASoC: tda7802: Add speaker-test sysfs

2019-06-11 Thread Thomas Preston
Add speaker_test device attribute. When the speaker-test node is read the hardware speaker test is started. $ cat /sys/devices/.../device:00/speaker_test 04 04 04 04 Signed-off-by: Thomas Preston Cc: Patrick Glaser Cc: Rob Duncan Cc: Nate Case --- sound/soc/codecs/tda7802.c

[PATCH v1 0/4] ASoC: Codecs: Add TDA7802 codec

2019-06-11 Thread Thomas Preston
This patch series adds a driver for the ST TDA7802 amplifier. Thanks, Thomas Cc: Patrick Glaser Cc: Rob Duncan Cc: Nate Case Thomas Preston (4): dt-bindings: ASoC: Add TDA7802 amplifier ASoC: Add codec driver for ST TDA7802 ASoC: tda7802: Add enable device attribute ASoC: tda7802

[PATCH v1 2/4] ASoC: Add codec driver for ST TDA7802

2019-06-11 Thread Thomas Preston
-off-by: Thomas Preston Cc: Patrick Glaser Cc: Rob Duncan Cc: Nate Case --- sound/soc/codecs/Kconfig | 6 + sound/soc/codecs/Makefile | 2 + sound/soc/codecs/tda7802.c | 580 + 3 files changed, 588 insertions(+) create mode 100644 sound/soc

[PATCH v1 3/4] ASoC: tda7802: Add enable device attribute

2019-06-11 Thread Thomas Preston
ces/.../device:00/enable echo 0 > /sys/devices/.../device:01/enable In an emergency, we can force disable from any device: echo -1 > /sys/devices/.../device:00/enable Signed-off-by: Thomas Preston Cc: Patrick Glaser Cc: Rob Duncan Cc: Nate Case --- sound/soc/codecs/tda78

[PATCH v3] Documentation: acpi: Add an example for PRP0001

2019-03-25 Thread Thomas Preston
Add an example for the magic PRP0001 device ID which allows matching ACPI devices against drivers using OF Device Tree compatible property. Signed-off-by: Thomas Preston --- Documentation/acpi/enumeration.txt | 26 ++ 1 file changed, 26 insertions(+) diff --git a

Re: [PATCH v2] Documentation: acpi: Add an example for PRP0001

2019-03-25 Thread Thomas Preston
On 25/03/2019 16:34, Andy Shevchenko wrote: On Mon, Mar 25, 2019 at 03:58:13PM +, Thomas Preston wrote: On 25/03/2019 15:30, Andy Shevchenko wrote: On Mon, Mar 25, 2019 at 03:12:10PM +, Thomas Preston wrote: Add an example for the magic PRP0001 device ID which allows matching ACPI

Re: [PATCH v2] Documentation: acpi: Add an example for PRP0001

2019-03-25 Thread Thomas Preston
On 25/03/2019 15:30, Andy Shevchenko wrote: On Mon, Mar 25, 2019 at 03:12:10PM +, Thomas Preston wrote: Add an example for the magic PRP0001 device ID which allows matching ACPI devices against drivers using OF Device Tree compatible property. It wasn't clear to me that PRP0001 cou

[PATCH v2] Documentation: acpi: Add an example for PRP0001

2019-03-25 Thread Thomas Preston
Add an example for the magic PRP0001 device ID which allows matching ACPI devices against drivers using OF Device Tree compatible property. It wasn't clear to me that PRP0001 could be used in _CID. Signed-off-by: Thomas Preston --- Documentation/acpi/enumeration.txt

Re: [PATCH] Documentation: acpi: Add an example for PRP0001

2019-03-25 Thread Thomas Preston
On 25/03/2019 15:01, Andy Shevchenko wrote: On Mon, Mar 25, 2019 at 02:42:09PM +, Thomas Preston wrote: On 25/03/2019 13:04, Andy Shevchenko wrote: On Mon, Mar 25, 2019 at 01:51:18PM +0200, Andy Shevchenko wrote: On Mon, Mar 25, 2019 at 10:31:13AM +0100, Rafael J. Wysocki wrote: Though

Re: [PATCH] Documentation: acpi: Add an example for PRP0001

2019-03-25 Thread Thomas Preston
Hi, Thanks for looking at this. On 25/03/2019 13:04, Andy Shevchenko wrote: On Mon, Mar 25, 2019 at 01:51:18PM +0200, Andy Shevchenko wrote: On Mon, Mar 25, 2019 at 10:31:13AM +0100, Rafael J. Wysocki wrote: On Fri, Mar 22, 2019 at 2:47 PM Thomas Preston wrote: Add an example for the magic

[PATCH] Documentation: acpi: Add an example for PRP0001

2019-03-22 Thread Thomas Preston
Add an example for the magic PRP0001 device ID which allows matching ACPI devices against drivers using OF Device Tree compatible property. It wasn't clear to me that PRP0001 could be used in _CID. Signed-off-by: Thomas Preston --- Documentation/acpi/enumeration.txt

Re: [PATCH] drm/i915/ddi: Fix default eDP detection on port A

2019-03-07 Thread Thomas Preston
On 07/03/2019 10:34, Jani Nikula wrote: There are dangers with default VBTs too. They might contain incorrect information about the specific board you have. You'll also have to set up the opregion, not just VBT. I'm afraid I can't help you there. You already know where to look to see how the ker

Re: [PATCH] drm/i915/ddi: Fix default eDP detection on port A

2019-03-07 Thread Thomas Preston
On 07/03/2019 10:34, Jani Nikula wrote: On Wed, 06 Mar 2019, Thomas Preston wrote: We rely on VBT DDI port info for eDP detection on GEN9 platforms and above. This breaks GEN9 platforms which don't have VBT because port A eDP now defaults to false. Fix this by defaulting to true when V

Re: [PATCH] drm/i915/ddi: Fix default eDP detection on port A

2019-03-07 Thread Thomas Preston
Hi, Thanks for looking at this. On 07/03/2019 08:18, Jani Nikula wrote: The subject should probably have "drm/i915/bios" or "drm/i915/vbt". Noted On Wed, 06 Mar 2019, Thomas Preston wrote: We rely on VBT DDI port info for eDP detection on GEN9 platforms and abo

[PATCH] drm/i915/ddi: Fix default eDP detection on port A

2019-03-06 Thread Thomas Preston
fo for eDP detection") Signed-off-by: Thomas Preston --- drivers/gpu/drm/i915/intel_bios.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/i915/intel_bios.c b/drivers/gpu/drm/i915/intel_bios.c index 1faa494e2bc9..efbbfb64b55f 100644 --- a/drivers/gpu/drm/i915/intel_bios.

[PATCH 0/2] vsprintf Stop using obsolete simple_strtoul()

2018-12-11 Thread Thomas Preston
simple_strtoull(), which we have replaced. Many thanks, Thomas Thomas Preston (2): vsprintf: Specify type for union val members vsprintf: Stop using obsolete simple_strtoul() lib/vsprintf.c | 66 ++ 1 file changed, 43 insertions(+), 23 deletions(-) -- 2.11.0

[PATCH 2/2] vsprintf: Stop using obsolete simple_strtoul()

2018-12-11 Thread Thomas Preston
ppens is the value gets divided down to zero. Signed-off-by: Thomas Preston Signed-off-by: Ben Dooks --- lib/vsprintf.c | 36 1 file changed, 28 insertions(+), 8 deletions(-) diff --git a/lib/vsprintf.c b/lib/vsprintf.c index bbf2ac734711..ec23e18e8cc6 100644

[PATCH 1/2] vsprintf: Specify type for union val members

2018-12-11 Thread Thomas Preston
using. Signed-off-by: Thomas Preston --- lib/vsprintf.c | 34 +- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/lib/vsprintf.c b/lib/vsprintf.c index 37a54a6dd594..bbf2ac734711 100644 --- a/lib/vsprintf.c +++ b/lib/vsprintf.c @@ -2914,8 +2914,8