Re: Oops: [RFC] LinuxPPS (pre)patch

From: Greg KH
Date: Sun Oct 21 2007 - 00:10:03 EST


On Fri, Oct 19, 2007 at 07:53:24PM +0200, Rodolfo Giometti wrote:
> +/* The main struct */
> +struct pps_device {
> + struct pps_source_info info; /* PSS source info */
> +
> + struct pps_kparams params; /* PPS's current params */
> +
> + __u32 assert_sequence; /* PPS' assert event seq # */
> + __u32 clear_sequence; /* PPS' clear event seq # */
> + struct pps_ktime assert_tu;
> + struct pps_ktime clear_tu;
> + int current_mode; /* PPS mode at event time */
> +
> + int go; /* PPS event is arrived? */
> + wait_queue_head_t queue; /* PPS event queue */
> +
> + unsigned int id; /* PPS source unique ID */
> + struct cdev cdev;
> + struct device *dev;
> + int devno;
> + struct fasync_struct *async_queue; /* fasync method */
> + spinlock_t lock;
> +
> + atomic_t usage; /* usage count */
> + wait_queue_head_t usage_queue;
> +
> + struct class_device class_dev;
> +};

Please use a 'struct class' instead of a 'struct class_device'. We have
almost rid the kernel of all usages of 'struct class_device' and want to
remove that structure entirely soon. I'm aiming for 2.6.25 and it's
looking good.

So please don't add new instances of it, you can do all the same things
with a 'struct device' and it should be a very trivial change.

thanks,

greg k-h
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/