Re: Cleanup proposal for media/gspca

2011-11-21 Thread Ezequiel
On Sun, Nov 20, 2011 at 08:24:29AM +0100, Jean-Francois Moine wrote: > > Hi Ezequiel, > > It is not a minor patch, but maybe you don't know about object > programming. > > As it is defined, a gspca device _is_ a video device, as a gspca > subdriver is a gspca device, and as a video device is a d

Re: Cleanup proposal for media/gspca

2011-11-19 Thread Jean-Francois Moine
On Sat, 19 Nov 2011 15:59:50 -0300 Ezequiel wrote: > Hi Jef, > > I just sent a patch to linux-media for this little issue. > > I realize it is only a very minor patch, > so I am not sure If I am helping or just annoying the developers ;) > > Anyway, if you could check the patch I would appre

Re: Cleanup proposal for media/gspca

2011-11-19 Thread Ezequiel
On Thu, Nov 17, 2011 at 11:07:16AM +0100, Jean-Francois Moine wrote: > On Wed, 16 Nov 2011 15:19:04 -0300 > Ezequiel Garc??a wrote: > > > In 'media/video/gspca/gspca.c' I really hated this cast (maybe because > > I am too dumb to understand it): > > > > gspca_dev = (struct gspca_dev *) video_d

Re: Cleanup proposal for media/gspca

2011-11-17 Thread Ezequiel
On Thu, Nov 17, 2011 at 11:07:16AM +0100, Jean-Francois Moine wrote: > On Wed, 16 Nov 2011 15:19:04 -0300 > Ezequiel Garc??a wrote: > > > In 'media/video/gspca/gspca.c' I really hated this cast (maybe because > > I am too dumb to understand it): > > > > gspca_dev = (struct gspca_dev *) video_d

Re: Cleanup proposal for media/gspca

2011-11-17 Thread Jean-Francois Moine
On Wed, 16 Nov 2011 15:19:04 -0300 Ezequiel García wrote: > In 'media/video/gspca/gspca.c' I really hated this cast (maybe because > I am too dumb to understand it): > > gspca_dev = (struct gspca_dev *) video_devdata(file); > > wich is only legal because a struct video_device is the first mem

Cleanup proposal for media/gspca

2011-11-16 Thread Ezequiel García
Hi folks, In 'media/video/gspca/gspca.c' I really hated this cast (maybe because I am too dumb to understand it): gspca_dev = (struct gspca_dev *) video_devdata(file); wich is only legal because a struct video_device is the first member of gspca_dev. IMHO, this is 'unnecesary obfuscation'. The