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: <d120d5000608290526i208885f4u9eed3269e1d3ffb1@mail.gmail.com>
Date:	Tue, 29 Aug 2006 08:26:46 -0400
From:	"Dmitry Torokhov" <dmitry.torokhov@...il.com>
To:	"Zephaniah E. Hull" <warp@...allh.com>
Cc:	"Komal Shah" <komal_shah802003@...oo.com>,
	linux-input@...ey.karlin.mff.cuni.cz, linux-kernel@...r.kernel.org,
	"Marcelo Tosatti" <mtosatti@...hat.com>
Subject: Re: [RPC] OLPC tablet input driver.

On 8/29/06, Zephaniah E. Hull <warp@...allh.com> wrote:
> On Tue, Aug 29, 2006 at 01:55:37AM -0700, Komal Shah wrote:
> > --- "Zephaniah E. Hull" <warp@...allh.com> wrote:
> > >
> > > -psmouse-objs  := psmouse-base.o alps.o logips2pp.o synaptics.o
> > > lifebook.o trackpoint.o
> > > +psmouse-objs  := psmouse-base.o alps.o logips2pp.o synaptics.o
> > > lifebook.o trackpoint.o olpc.o
> >
> > Where is KConfigurable entry ?
>
> It is a component of psmouse.o, which is a few lines up.
>
> Breaking out the components of psmouse.o into separate configuration
> items might be interesting, but it is quite a bit beyond the scope of
> this patch.

Is there a chance that this device will be used on generally-available
hardware? If not then having Kconfig sub-option would be nice.

> >
> > > diff --git a/drivers/input/mouse/olpc.c b/drivers/input/mouse/olpc.c
> > > new file mode 100644
> > > index 0000000..245f29e
> > > --- /dev/null
> > > +++ b/drivers/input/mouse/olpc.c
> > > @@ -0,0 +1,327 @@
> >
> >
> > > +/*
> > > + * OLPC touchpad PS/2 mouse driver
> > > + *
> > > +int olpc_init(struct psmouse *psmouse)
> > > +{
> > > +   struct olpc_data *priv;
> > > +   struct input_dev *dev = psmouse->dev;
> > > +   struct input_dev *dev2;
> > > +
> > > +   psmouse->private = priv = kzalloc(sizeof(struct olpc_data),
> > > GFP_KERNEL);
> >
> > I think you should assign priv to private only if !NULL.
>
> Fixed.
>
> It should not actually matter, as a failure to get a !NULL value causes
> us to return false, which will fall over to other psmouse drivers which
> will either set it themselves, or not use it at all, however.
>
> It should be noted that alps.c contains the same issue.
>

I do not consider this is an issue. priv is just a shortcut or alias
for psmouse->private that saves some typing and allows the compiled to
generate better code.

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ