On Tuesday 30 May 2006 23:43, Francois Romieu wrote: > Ivo van Doorn <[EMAIL PROTECTED]> : > [...] > > diff --git a/drivers/input/misc/radiobtn.c b/drivers/input/misc/radiobtn.c > > new file mode 100644 > > index 0000000..8d3b84a > > --- /dev/null > > +++ b/drivers/input/misc/radiobtn.c > [...] > > +void radiobtn_poll(unsigned long data) > > static ?
Good point. Will fix this immediately.
> [...]
> > +int radiobtn_register_device(struct radio_button *radiobtn)
> > +{
> > + int status;
> > +
> > + /*
> > + * Check if all mandatory fields have been set.
> > + */
> > + if (radiobtn->poll_delay == 0 || radiobtn->button_poll == NULL)
> > + return -EINVAL;
> > +
> > + /*
> > + * Allocate, initialize and register input device.
> > + */
> > + radiobtn->input_dev = input_allocate_device();
> > + if (!radiobtn->input_dev) {
> > + printk(KERN_ERR "Failed to allocate input device %s.\n",
> > + radiobtn->dev_name);
> > + return -ENOMEM;
> > + }
> > +
> > + radiobtn->input_dev->name = "Radio button";
> > + radiobtn->input_dev->phys = strcat("radiobtn/", radiobtn->dev_name);
>
> The first parameter of strcat() must be big enough to contain the whole
> string.
Will replace it with
sprintf(wrqu->name, "radiobtn/", radiobtn->dev_name);
Thanks.
Ivo
pgp9nZql2WkSp.pgp
Description: PGP signature
