From: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: Jonathan Corbet <corbet@lwn.net>, Jean Delvare <jdelvare@suse.de>,
Wolfram Sang <wsa@the-dreams.de>,
Willy Tarreau <willy@meta-x.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk>,
linux-i2c@vger.kernel.org, devel@driverdev.osuosl.org,
linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org
Subject: Re: [PATCH 1/4] parport: modify parport subsystem to use devicemodel
Date: Wed, 15 Apr 2015 15:58:04 +0530 [thread overview]
Message-ID: <20150415102804.GA3803@sudip-PC> (raw)
In-Reply-To: <20150415094500.GZ16501@mwanda>
On Wed, Apr 15, 2015 at 12:45:00PM +0300, Dan Carpenter wrote:
> On Wed, Apr 15, 2015 at 02:50:55PM +0530, Sudip Mukherjee wrote:
> > <snip>
> > > > + tmp->name = name;
> > >
> > > I wonder who frees this name variable. My concern is that it gets
> > > freed before we are done using it or something. (I have not looked at
> > > the details).
> > it will be done in free_port() the release callback of parport device.
>
> That doesn't work. Some of the callers pass a string literal.
oops, when i replied to your first mail about this I looked at
parport_register_port(), but the one that you have mentioned is the one
I gave in parport_register_dev() and it seems that the name is not freed
anywhere except the driver that has called parport_register_device() or
parport_register_dev(). I think I should better copy it and then give it
to tmp->name and free it also in the unregister function. And this should
be fixed in the original parport_register_device() also.
I will wait for some more reviews send the v2 series tomorrow.
regards
sudip
>
> regards,
> dan carpenter
>
next prev parent reply other threads:[~2015-04-15 10:28 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-15 7:48 [PATCH 0/4] convert parport to device-model Sudip Mukherjee
2015-04-15 7:48 ` Sudip Mukherjee
2015-04-15 7:48 ` [PATCH 1/4] parport: modify parport subsystem to use devicemodel Sudip Mukherjee
2015-04-15 7:48 ` Sudip Mukherjee
2015-04-15 8:27 ` Dan Carpenter
2015-04-15 8:27 ` Dan Carpenter
2015-04-15 9:20 ` Sudip Mukherjee
2015-04-15 9:20 ` Sudip Mukherjee
2015-04-15 9:32 ` Dan Carpenter
2015-04-15 9:32 ` Dan Carpenter
2015-04-15 9:45 ` Dan Carpenter
2015-04-15 9:45 ` Dan Carpenter
2015-04-15 10:28 ` Sudip Mukherjee [this message]
2015-04-15 8:33 ` Dan Carpenter
2015-04-15 8:33 ` Dan Carpenter
2015-04-15 9:24 ` Sudip Mukherjee
2015-04-15 13:23 ` Greg Kroah-Hartman
2015-04-15 13:23 ` Greg Kroah-Hartman
2015-04-15 13:31 ` Greg Kroah-Hartman
[not found] ` <20150415133115.GG21491-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
2015-04-15 16:13 ` Sudip Mukherjee
2015-04-15 16:13 ` Sudip Mukherjee
2015-04-16 9:50 ` Sudip Mukherjee
2015-04-15 7:48 ` [PATCH 2/4] parport: update TODO and documentation Sudip Mukherjee
2015-04-15 7:48 ` [PATCH 3/4] i2c-parport: use device-model parport Sudip Mukherjee
2015-04-15 7:48 ` Sudip Mukherjee
2015-04-15 7:48 ` [PATCH 4/4] staging: panel: use parport in device-model Sudip Mukherjee
2015-04-15 7:48 ` Sudip Mukherjee
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150415102804.GA3803@sudip-PC \
--to=sudipm.mukherjee@gmail.com \
--cc=corbet@lwn.net \
--cc=dan.carpenter@oracle.com \
--cc=devel@driverdev.osuosl.org \
--cc=gnomes@lxorguk.ukuu.org.uk \
--cc=gregkh@linuxfoundation.org \
--cc=jdelvare@suse.de \
--cc=linux-doc@vger.kernel.org \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=willy@meta-x.org \
--cc=wsa@the-dreams.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.