Re: [Pcihpd-discuss] [PATCH 5/6]: hotplug/ia64: SN Hotplug Driver - SN Hotplug Driver code

From: Greg KH <greg_at_kroah.com>
Date: 2005-05-21 04:26:59
On Fri, May 20, 2005 at 08:11:30AM -0400, Prarit Bhargava wrote:
> +static struct hotplug_slot_attribute sn_slot_attrs[] = {
> +	__ATTR_RO(path),
> +	__ATTR_NULL
> +};

Why are you having an array with only 1 attribute?  Just define the one,
and live with it.  That way you can get rid of all of your odd loops.

And if you do want to stick with an array, use the proper sysfs call to
register and unregister all of them at once, don't roll your own code to
do this.

greg k-h
-
To unsubscribe from this list: send the line "unsubscribe linux-ia64" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Received on Fri May 20 16:56:20 2005

This archive was generated by hypermail 2.1.8 : 2005-08-02 09:20:39 EST