Re: [PATCH 3/3] usb: gadget: storage: Remove EXPORT_SYMBOL_GPL for kref_{put, get}

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 15 Jun 2018, Jaejoong Kim wrote:

> Thanks for the review it.
> 
> 2018년 6월 14일 (목) 오후 11:48, Alan Stern <stern@xxxxxxxxxxxxxxxxxxx>님이 작성:
> >
> > On Thu, 14 Jun 2018, Jaejoong Kim wrote:
> >
> > > Removing EXPORT_SYMBOL_GPL from kref_{put, get} since it is used
> > > only in f_mass_storage
> > >
> > > Signed-off-by: Jaejoong Kim <climbbb.kim@xxxxxxxxx>
> >
> > This is only a partial solution.  In fact, fsg_common_get() isn't used
> > anywhere, and fsg_common_put() is used in only one place.
> 
> Right. Actually my first approach was to remove fsg_common_get/put and just
> use kref APIs(kref_get/put). But I kept current codes because this module author
> might have another reason.
> 
> >
> > It would be better to remove those two routines, get rid of common->ref
> > entirely, and make fsg_free_inst() call fsg_common_release() directly.
> 
> Hm.. If you want to call fsg_common_release () in fsg_free_inst (),
> the struct kref
> in this moduel is meaningless. I prefer hold kref and just use kref APIs not
> fsg_common_get/put.

Michal Nazarewicz is the author of this part of the driver.  He should
make the decision of whether to keep the kref or eliminate it.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux