lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID:
 <PH0PR12MB54810AC135B9810C9BC32C8EDC1C2@PH0PR12MB5481.namprd12.prod.outlook.com>
Date: Mon, 6 May 2024 15:15:39 +0000
From: Parav Pandit <parav@...dia.com>
To: Shay Drori <shayd@...dia.com>, "netdev@...r.kernel.org"
	<netdev@...r.kernel.org>, "pabeni@...hat.com" <pabeni@...hat.com>,
	"davem@...emloft.net" <davem@...emloft.net>, "kuba@...nel.org"
	<kuba@...nel.org>, "edumazet@...gle.com" <edumazet@...gle.com>,
	"gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
	"david.m.ertman@...el.com" <david.m.ertman@...el.com>
CC: "rafael@...nel.org" <rafael@...nel.org>, "ira.weiny@...el.com"
	<ira.weiny@...el.com>, "linux-rdma@...r.kernel.org"
	<linux-rdma@...r.kernel.org>, "leon@...nel.org" <leon@...nel.org>, Tariq
 Toukan <tariqt@...dia.com>
Subject: RE: [PATCH net-next v2 1/2] driver core: auxiliary bus: show
 auxiliary device IRQs


> From: Shay Drori <shayd@...dia.com>
> Sent: Sunday, May 5, 2024 7:53 AM


> diff --git a/include/linux/auxiliary_bus.h b/include/linux/auxiliary_bus.h
> index de21d9d24a95..fe2c438c0217 100644
> --- a/include/linux/auxiliary_bus.h
> +++ b/include/linux/auxiliary_bus.h
> @@ -58,6 +58,9 @@
>   *       in
>   * @name: Match name found by the auxiliary device driver,
>   * @id: unique identitier if multiple devices of the same name are exported,
> + * @irqs: irqs xarray contains irq indices which are used by the
> + device,
> + * @groups: first group is for irqs sysfs directory; it is a NULL terminated
> + *          array,
>   *
>   * An auxiliary_device represents a part of its parent device's functionality.
>   * It is given a name that, combined with the registering drivers @@ -138,6
> +141,8 @@  struct auxiliary_device {
>  	struct device dev;
>  	const char *name;
> +	struct xarray irqs;
> +	const struct attribute_group *groups[2];
>  	u32 id;
>  };
> 
> @@ -209,8 +214,19 @@ static inline struct auxiliary_driver
> *to_auxiliary_drv(struct device_driver *dr  }
> 
>  int auxiliary_device_init(struct auxiliary_device *auxdev); -int
> __auxiliary_device_add(struct auxiliary_device *auxdev, const char
> *modname); -#define auxiliary_device_add(auxdev)
> __auxiliary_device_add(auxdev, KBUILD_MODNAME)
> +int __auxiliary_device_add(struct auxiliary_device *auxdev, const char
> *modname,
> +			   bool irqs_sysfs_enable);
> +#define auxiliary_device_add(auxdev) __auxiliary_device_add(auxdev,
> +KBUILD_MODNAME, false) #define auxiliary_device_add_with_irqs(auxdev)
> \
> +	__auxiliary_device_add(auxdev, KBUILD_MODNAME, true)
> +

> +#ifdef CONFIG_SYSFS
> +int auxiliary_device_sysfs_irq_add(struct auxiliary_device *auxdev, int
> +irq); void auxiliary_device_sysfs_irq_remove(struct auxiliary_device
> +*auxdev, int irq); #else /* CONFIG_SYSFS */ int
> +auxiliary_device_sysfs_irq_add(struct auxiliary_device *auxdev, int
> +irq) {return 0; } void auxiliary_device_sysfs_irq_remove(struct
> +auxiliary_device *auxdev, int irq) {} #endif
>
Above definitions need to be static inline and should under 80 characters.
Please fix them.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ