Re: [PATCH 2/2] usb: typec: Add onsemi FUSB15201 driver
From: Uwe Kleine-König
Date: Mon Sep 07 2026 - 04:44:20 EST
Hello Shawn,
On Wed, Sep 02, 2026 at 12:59:38PM +0800, Shawn Guo wrote:
> +#include <linux/i2c.h>
> [...]
> +#include <linux/mod_devicetable.h>
Please rely on <linux/i2c.h> to provide of_device_id and (see below)
i2c_device_id. Alternatively include the needed files below
include/linux/device-id/ to not introduce unneeded dependencies.
> +static const struct of_device_id fusb15201_of_match[] = {
> + { .compatible = "onnn,fusb15201" },
> + { }
> +};
> +MODULE_DEVICE_TABLE(of, fusb15201_of_match);
> +
> +static struct i2c_driver fusb15201_driver = {
> + .driver = {
> + .name = "fusb15201",
> + .of_match_table = fusb15201_of_match,
> + },
> + .probe = fusb15201_probe,
Don't you need an i2c_device_id table, too?
> +};
> +module_i2c_driver(fusb15201_driver);
Best regards
Uwe
Attachment:
signature.asc
Description: PGP signature