mbox series

[v9,0/7] Netronix embedded controller driver for Kobo and Tolino ebook readers

Message ID 20210124214127.3631530-1-j.neuschaefer@gmx.net
Headers show
Series Netronix embedded controller driver for Kobo and Tolino ebook readers | expand

Message

J. Neuschäfer Jan. 24, 2021, 9:41 p.m. UTC
This patchset adds basic support for the embedded controller found on
older ebook reader boards designed by/with the ODM Netronix Inc.[1] and
sold by Kobo or Tolino, for example the Kobo Aura and the Tolino Shine.
These drivers are based on information contained in the vendor kernel
sources, but in order to all information in a single place, I documented
the register interface of the EC on GitHub[2].

[1]: http://www.netronixinc.com/products.aspx?ID=1
[2]: https://github.com/neuschaefer/linux/wiki/Netronix-MSP430-embedded-controller

v9:
- Fixed a bug in the error handling of ntxec_probe,
  Reported-by: kernel test robot <lkp@intel.com>
- Added Thierry Reding's ACK to the PWM patch

v8:
- https://lore.kernel.org/lkml/20210116194826.3866540-1-j.neuschaefer@gmx.net/
- MFD: Add missing module metadata to the core driver
- PWM/RTC: Copy dev.of_node from the parent device, to ensure that these
  devices are linked to the devicetree node

v7:
- https://lore.kernel.org/lkml/20210109180220.121511-1-j.neuschaefer@gmx.net/
- Adjust the RTC patch to a change in the RTC API:
  rtc_register_device is now devm_rtc_register_device.
- Add a #define for the known firmware version (0xd726).
  Lee Jones suggested doing this in a follow-up patch, but since I'm
  respinning the series anyway, I'm doing it here.



Jonathan Neuschäfer (7):
  dt-bindings: Add vendor prefix for Netronix, Inc.
  dt-bindings: mfd: Add binding for Netronix embedded controller
  mfd: Add base driver for Netronix embedded controller
  pwm: ntxec: Add driver for PWM function in Netronix EC
  rtc: New driver for RTC in Netronix embedded controller
  MAINTAINERS: Add entry for Netronix embedded controller
  ARM: dts: imx50-kobo-aura: Add Netronix embedded controller

 .../bindings/mfd/netronix,ntxec.yaml          |  76 ++++++
 .../devicetree/bindings/vendor-prefixes.yaml  |   2 +
 MAINTAINERS                                   |   9 +
 arch/arm/boot/dts/imx50-kobo-aura.dts         |  16 +-
 drivers/mfd/Kconfig                           |  11 +
 drivers/mfd/Makefile                          |   1 +
 drivers/mfd/ntxec.c                           | 221 ++++++++++++++++++
 drivers/pwm/Kconfig                           |   8 +
 drivers/pwm/Makefile                          |   1 +
 drivers/pwm/pwm-ntxec.c                       | 184 +++++++++++++++
 drivers/rtc/Kconfig                           |   8 +
 drivers/rtc/Makefile                          |   1 +
 drivers/rtc/rtc-ntxec.c                       | 145 ++++++++++++
 include/linux/mfd/ntxec.h                     |  37 +++
 14 files changed, 719 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/devicetree/bindings/mfd/netronix,ntxec.yaml
 create mode 100644 drivers/mfd/ntxec.c
 create mode 100644 drivers/pwm/pwm-ntxec.c
 create mode 100644 drivers/rtc/rtc-ntxec.c
 create mode 100644 include/linux/mfd/ntxec.h

--
2.29.2

Comments

Andreas Kemnade Feb. 8, 2021, 9:56 p.m. UTC | #1
On Sun, 24 Jan 2021 22:41:20 +0100
Jonathan Neuschäfer <j.neuschaefer@gmx.net> wrote:

> This patchset adds basic support for the embedded controller found on
> older ebook reader boards designed by/with the ODM Netronix Inc.[1] and
> sold by Kobo or Tolino, for example the Kobo Aura and the Tolino Shine.
> These drivers are based on information contained in the vendor kernel
> sources, but in order to all information in a single place, I documented
> the register interface of the EC on GitHub[2].
> 
> [1]: http://www.netronixinc.com/products.aspx?ID=1
> [2]: https://github.com/neuschaefer/linux/wiki/Netronix-MSP430-embedded-controller
> 
> v9:
> - Fixed a bug in the error handling of ntxec_probe,
>   Reported-by: kernel test robot <lkp@intel.com>
> - Added Thierry Reding's ACK to the PWM patch
> 
what is the fate of this one, looks like it got all acks from
maintainers.

Regards,
Andreas
Lee Jones Feb. 9, 2021, 2:11 p.m. UTC | #2
On Mon, 08 Feb 2021, Andreas Kemnade wrote:

> On Sun, 24 Jan 2021 22:41:20 +0100
> Jonathan Neuschäfer <j.neuschaefer@gmx.net> wrote:
> 
> > This patchset adds basic support for the embedded controller found on
> > older ebook reader boards designed by/with the ODM Netronix Inc.[1] and
> > sold by Kobo or Tolino, for example the Kobo Aura and the Tolino Shine.
> > These drivers are based on information contained in the vendor kernel
> > sources, but in order to all information in a single place, I documented
> > the register interface of the EC on GitHub[2].
> > 
> > [1]: http://www.netronixinc.com/products.aspx?ID=1
> > [2]: https://github.com/neuschaefer/linux/wiki/Netronix-MSP430-embedded-controller
> > 
> > v9:
> > - Fixed a bug in the error handling of ntxec_probe,
> >   Reported-by: kernel test robot <lkp@intel.com>
> > - Added Thierry Reding's ACK to the PWM patch
> > 
> what is the fate of this one, looks like it got all acks from
> maintainers.

I'll apply it when -rc1 is out.
Shawn Guo March 3, 2021, 7:59 a.m. UTC | #3
On Sun, Jan 24, 2021 at 10:41:27PM +0100, Jonathan Neuschäfer wrote:
> Enable the Netronix EC on the Kobo Aura ebook reader.
> 
> Several features are still missing:
>  - Frontlight/backlight. The vendor kernel drives the frontlight LED
>    using the PWM output of the EC and an additional boost pin that
>    increases the brightness.
>  - Battery monitoring
>  - Interrupts for RTC alarm and low-battery events
> 
> Signed-off-by: Jonathan Neuschäfer <j.neuschaefer@gmx.net>

Applied, thanks.