Re: question regarding drivers/staging/iio/adc/ad7280a.c

2014-07-17 Thread Greg Kroah-Hartman
On Thu, Jul 17, 2014 at 01:58:15PM -0700, Greg Kroah-Hartman wrote: > On Thu, Jul 17, 2014 at 11:40:04PM +0530, Himangi Saraogi wrote: > > Hi, > > > > I have sent in a patch for adding devm_kasprintf > > https://lkml.org/lkml/2014/7/ > > 16/667. > > I will be updating this file and send in a patc

Re: question regarding drivers/staging/iio/adc/ad7280a.c

2014-07-17 Thread Greg Kroah-Hartman
On Thu, Jul 17, 2014 at 11:40:04PM +0530, Himangi Saraogi wrote: > Hi, > > I have sent in a patch for adding devm_kasprintf https://lkml.org/lkml/2014/7/ > 16/667. > I will be updating this file and send in a patch once it is accepted. Was it > the right thing > to do to send the devm_kasprintf pa

Re: question regarding drivers/staging/iio/adc/ad7280a.c

2014-07-16 Thread Lars-Peter Clausen
On 07/15/2014 07:31 PM, Jonathan Cameron wrote: On 14/07/14 21:31, Himangi Saraogi wrote: Hi, The code seems to have a memory leak. The function ad7280_attr_init calls kasprintf a number of times, which calls kmalloc (or more precisely kmalloc_track_caller), but this data does not ever seem to

Re: question regarding drivers/staging/iio/adc/ad7280a.c

2014-07-15 Thread Jonathan Cameron
On 14/07/14 21:31, Himangi Saraogi wrote: Hi, The code seems to have a memory leak. The function ad7280_attr_init calls kasprintf a number of times, which calls kmalloc (or more precisely kmalloc_track_caller), but this data does not ever seem to be freed. I propose to introduce a devm_ version