Re: [PATCHv6 0/4] n_gsm serdev support and protocol driver for droid4 modem

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Tony,

On Tue, Apr 21, 2020 at 04:27:48PM -0700, Tony Lindgren wrote:
> Hi all,
> 
> Here's v4 set of n_gsm serdev support patches, and the related protocol
> driver for the modem found on Motorola Mapphone phones and tablets
> like droid4.
> 
> This series only adds basic character device support for the serdev
> driver. Other serdev consumer drivers for specific devices will be
> posted separately.

I'm still missing an architectural (design) overview here -- reviewer
time is a scarce resource.

I also suggested earlier that you include, at least as an RFC, one or
more of your child-device drivers so that we can see how this ends up
being used in the end (including an example devicetree).

Some high-level comments until then:

I'm not sure that a plain chardev interface for the mux channels is the
right interface. The n_gsm ldisc exposes tty devices and I think your
serdev adaptation should continue to do that.

On that note; you're not actually adding general TS 27.010 serdev
support, but rather some hooks and a custom driver and interface (mfd +
/dev/motmdmN) for one particular modem.

I'd rather see a generic implementation which can be used with other
modems and that continues to expose a /dev/gsmttyN interface to which we
could attach serdev clients instead (and not create a motmdm serdev
replica of sorts).

I know the location of this driver has been up for discussion already,
but drivers/tty/serdev/protocol still isn't right (e.g. we don't have an
drivers/i2c/protocol directory where we stuff random i2c client
drivers).

It's an mfd + custom chardev driver for a modem and related to n_gsm
(even more if you add generic serdev support). Currently, drivers/mfd or
drivers/misc appear to be better choices. Otherwise, n_gsm lives in
drivers/tty since it's a line discipline, but it could be moved to a new
drivers/modem if needed (cf. the bluetooth hci ldisc).

Last, it seems you've based the serdev-ngsm-motmdm.c chardev
implementation on a more or less verbatim copy of drivers/gnss/core.c.
I'd appreciate if you could mention that in the file header and
reproduce the copyright notice if you end up keeping that interface.

> Tony Lindgren (4):
>   tty: n_gsm: Add support for serdev drivers
>   serdev: ngsm-motmdm: Add Motorola TS 27.010 serdev modem driver for
>     droid4
>   dt-bindings: serdev: motmdm: Add binding for motorola-mdm
>   ARM: dts: omap4-droid4: Enable basic modem support
> 
>  .../serdev/motorola,mapphone-mdm6600.yaml     |   34 +
>  .../boot/dts/motorola-mapphone-common.dtsi    |    6 +
>  drivers/tty/n_gsm.c                           |  372 +++++
>  drivers/tty/serdev/Kconfig                    |    2 +
>  drivers/tty/serdev/Makefile                   |    2 +
>  drivers/tty/serdev/protocol/Kconfig           |   14 +
>  drivers/tty/serdev/protocol/Makefile          |    3 +
>  .../tty/serdev/protocol/serdev-ngsm-motmdm.c  | 1191 +++++++++++++++++
>  include/linux/serdev-gsm.h                    |  168 +++
>  9 files changed, 1792 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/serdev/motorola,mapphone-mdm6600.yaml
>  create mode 100644 drivers/tty/serdev/protocol/Kconfig
>  create mode 100644 drivers/tty/serdev/protocol/Makefile
>  create mode 100644 drivers/tty/serdev/protocol/serdev-ngsm-motmdm.c
>  create mode 100644 include/linux/serdev-gsm.h

Johan



[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux