Hi, On 11/15/20 8:21 PM, Maximilian Luz wrote: > Hello, > > N.B.: the following text is mostly a repeat of cover letter from the > previous RFC for the uninitiated, which can be found at > > https://lore.kernel.org/linux-serial/20200923151511.3842150-1-luzmaximilian@xxxxxxxxx/ > > See "Changes" below for an overview of differences between the RFC and > this patchset. I hope I have addressed all comments from that in this > version, thank you again for those. > > The Surface System Aggregator Module (we'll refer to it as Surface > Aggregator or SAM below) is an embedded controller (EC) found on various > Microsoft Surface devices. Specifically, all 4th and later generation > Surface devices, i.e. Surface Pro 4, Surface Book 1 and later, with the > exception of the Surface Go series and the Surface Duo. Notably, it > seems like this EC can also be found on the ARM-based Surface Pro X [1]. <snip> > This patch-set can also be found at the following repository and > reference, if you prefer to look at a kernel tree instead of these > emails: > > https://github.com/linux-surface/kernel tags/s/surface-aggregator/v1 > > Thanks, > Max Thank you for your work on this. It would be great if we can get better support for the Surface line in the mainline kernel. Since a lot of people have already commented on this series I think that you have enough feedback to do a v2 addressing that feedback right? For now I'm going to assume that you will do a v2 addressing the initial round of comments and not review this myself (IOW I'll review this when v2 is posted). Let me know if you see things differently. Regards, Hans > [1]: The Surface Pro X is, however, currently considered unsupported due > to a lack of test candidates and, as it seems, general lack of > Linux support on other parts. AFAIK there is an issue preventing > serial devices from being registered, on which the core driver in > this series is build on, thus there is no way to even test that at > this point. I'd be happy to work out any issues regarding SAM on > the Pro X at some point in the future, provided someone can/wants > to actually test it. > > [2]: https://github.com/linux-surface/surface-aggregator-module > [3]: https://github.com/linux-surface/linux-surface > > > Note: This patch depends on > > [PATCH v4] platform/surface: Create a platform subdirectory for > Microsoft Surface devices > > which can be found at > > https://lore.kernel.org/platform-driver-x86/20201009141128.683254-1-luzmaximilian@xxxxxxxxx/ > > and is currently in platform-drivers-x86/for-next. > > > Changes from the previous RFC (overview): > - move to platform/surface > - add copyright lines > - change SPDX identifier to GPL-2.0+ (was GPL-2.0-or-later) > - change user-space interface from debugfs to misc-device > - address issues in user-space interface > - fix typos in commit messages and documentation > - fix some bugs, address other issues > > Changes regarding specific patches (and more details) can be found on > the individual patch. > > > Maximilian Luz (9): > platform/surface: Add Surface Aggregator subsystem > platform/surface: aggregator: Add control packet allocation caching > platform/surface: aggregator: Add event item allocation caching > platform/surface: aggregator: Add trace points > platform/surface: aggregator: Add error injection capabilities > platform/surface: aggregator: Add dedicated bus and device type > docs: driver-api: Add Surface Aggregator subsystem documentation > platform/surface: Add Surface Aggregator user-space interface > platform/surface: Add Surface ACPI Notify driver > > Documentation/driver-api/index.rst | 1 + > .../surface_aggregator/client-api.rst | 38 + > .../driver-api/surface_aggregator/client.rst | 394 +++ > .../surface_aggregator/clients/cdev.rst | 85 + > .../surface_aggregator/clients/index.rst | 21 + > .../surface_aggregator/clients/san.rst | 44 + > .../driver-api/surface_aggregator/index.rst | 21 + > .../surface_aggregator/internal-api.rst | 67 + > .../surface_aggregator/internal.rst | 50 + > .../surface_aggregator/overview.rst | 76 + > .../driver-api/surface_aggregator/ssh.rst | 343 +++ > MAINTAINERS | 13 + > drivers/platform/surface/Kconfig | 39 + > drivers/platform/surface/Makefile | 3 + > drivers/platform/surface/aggregator/Kconfig | 65 + > drivers/platform/surface/aggregator/Makefile | 17 + > drivers/platform/surface/aggregator/bus.c | 424 +++ > drivers/platform/surface/aggregator/bus.h | 27 + > .../platform/surface/aggregator/controller.c | 2557 +++++++++++++++++ > .../platform/surface/aggregator/controller.h | 288 ++ > drivers/platform/surface/aggregator/core.c | 831 ++++++ > .../platform/surface/aggregator/ssh_msgb.h | 201 ++ > .../surface/aggregator/ssh_packet_layer.c | 2009 +++++++++++++ > .../surface/aggregator/ssh_packet_layer.h | 175 ++ > .../platform/surface/aggregator/ssh_parser.c | 229 ++ > .../platform/surface/aggregator/ssh_parser.h | 157 + > .../surface/aggregator/ssh_request_layer.c | 1254 ++++++++ > .../surface/aggregator/ssh_request_layer.h | 142 + > drivers/platform/surface/aggregator/trace.h | 625 ++++ > .../platform/surface/surface_acpi_notify.c | 884 ++++++ > .../surface/surface_aggregator_cdev.c | 299 ++ > include/linux/mod_devicetable.h | 18 + > include/linux/surface_acpi_notify.h | 39 + > include/linux/surface_aggregator/controller.h | 832 ++++++ > include/linux/surface_aggregator/device.h | 430 +++ > include/linux/surface_aggregator/serial_hub.h | 659 +++++ > include/uapi/linux/surface_aggregator/cdev.h | 58 + > scripts/mod/devicetable-offsets.c | 8 + > scripts/mod/file2alias.c | 23 + > 39 files changed, 13446 insertions(+) > create mode 100644 Documentation/driver-api/surface_aggregator/client-api.rst > create mode 100644 Documentation/driver-api/surface_aggregator/client.rst > create mode 100644 Documentation/driver-api/surface_aggregator/clients/cdev.rst > create mode 100644 Documentation/driver-api/surface_aggregator/clients/index.rst > create mode 100644 Documentation/driver-api/surface_aggregator/clients/san.rst > create mode 100644 Documentation/driver-api/surface_aggregator/index.rst > create mode 100644 Documentation/driver-api/surface_aggregator/internal-api.rst > create mode 100644 Documentation/driver-api/surface_aggregator/internal.rst > create mode 100644 Documentation/driver-api/surface_aggregator/overview.rst > create mode 100644 Documentation/driver-api/surface_aggregator/ssh.rst > create mode 100644 drivers/platform/surface/aggregator/Kconfig > create mode 100644 drivers/platform/surface/aggregator/Makefile > create mode 100644 drivers/platform/surface/aggregator/bus.c > create mode 100644 drivers/platform/surface/aggregator/bus.h > create mode 100644 drivers/platform/surface/aggregator/controller.c > create mode 100644 drivers/platform/surface/aggregator/controller.h > create mode 100644 drivers/platform/surface/aggregator/core.c > create mode 100644 drivers/platform/surface/aggregator/ssh_msgb.h > create mode 100644 drivers/platform/surface/aggregator/ssh_packet_layer.c > create mode 100644 drivers/platform/surface/aggregator/ssh_packet_layer.h > create mode 100644 drivers/platform/surface/aggregator/ssh_parser.c > create mode 100644 drivers/platform/surface/aggregator/ssh_parser.h > create mode 100644 drivers/platform/surface/aggregator/ssh_request_layer.c > create mode 100644 drivers/platform/surface/aggregator/ssh_request_layer.h > create mode 100644 drivers/platform/surface/aggregator/trace.h > create mode 100644 drivers/platform/surface/surface_acpi_notify.c > create mode 100644 drivers/platform/surface/surface_aggregator_cdev.c > create mode 100644 include/linux/surface_acpi_notify.h > create mode 100644 include/linux/surface_aggregator/controller.h > create mode 100644 include/linux/surface_aggregator/device.h > create mode 100644 include/linux/surface_aggregator/serial_hub.h > create mode 100644 include/uapi/linux/surface_aggregator/cdev.h >