[PATCH 05/13] spi: add driver for intel graphics on-die spi device

Usyskin, Alexander alexander.usyskin at intel.com
Thu Apr 25 11:58:40 UTC 2024


> > +static const struct auxiliary_device_id intel_dg_spi_id_table[] = {
> > +	{
> > +		.name = "i915.spi",
> > +	},
> > +	{
> > +		.name = "xe.spi",
> > +	},
> > +	{
> > +		/* sentinel */
> > +	}
> > +};
> > +MODULE_DEVICE_TABLE(auxiliary, intel_dg_spi_id_table);
> > +
> > +static struct auxiliary_driver intel_dg_spi_driver = {
> > +	.probe  = intel_dg_spi_probe,
> > +	.remove = intel_dg_spi_remove,
> > +	.driver = {
> > +		/* auxiliary_driver_register() sets .name to be the modname */
> > +	},
> > +	.id_table = intel_dg_spi_id_table
> > +};
> > +
> > +module_auxiliary_driver(intel_dg_spi_driver);
> > +
> > +MODULE_ALIAS("auxiliary:i915.spi");
> > +MODULE_ALIAS("auxiliary:xe.spi");
> 
> You should not need MODULE_ALIAS() in normal cases. If you need it,
> usually it means your device ID table is wrong (e.g. misses either
> entries or MODULE_DEVICE_TABLE()). MODULE_ALIAS() is not a substitute
> for incomplete ID table.
> 
> 
> Best regards,
> Krzysztof

You are right, the auxiliary bus process aliases in the right way,
this is remnants from the platform device usage, will drop.

-- 
Thanks,
Sasha




More information about the Intel-gfx mailing list