Re: [PATCH v1 2/5] fpga: altera-pr-ip: Remove fpga_mgr_unregister() call

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

 




On 6/9/21 8:37 AM, Xu Yilun wrote:
> On Tue, Jun 08, 2021 at 05:49:22PM -0700, Russ Weight wrote:
>> The altera-pr-ip driver uses the devm_fpga_mgr_register() call, so it is
>> unnecessary to call fpga_mgr_unregister(). Also, mgr is no longer stored
>> in the dev.driver_data, so remove the call to dev_get_drvdata().
>>
>> alt_pr_unregister() is now an empty function, but is left intact because
>> it is an exported symbol.
> I don't see this function be called anywhere, so could we just remove
> it?
>
> Any impact we remove an exported symbol that is not used?

Only if there are out-of-tree drivers that use it. What do other's think? Can we remove this?

- Russ
>
> Thanks,
> Yilun
>
>> Signed-off-by: Russ Weight <russell.h.weight@xxxxxxxxx>
>> ---
>>  drivers/fpga/altera-pr-ip-core.c | 4 ----
>>  1 file changed, 4 deletions(-)
>>
>> diff --git a/drivers/fpga/altera-pr-ip-core.c b/drivers/fpga/altera-pr-ip-core.c
>> index 5b130c4d9882..c150a084e440 100644
>> --- a/drivers/fpga/altera-pr-ip-core.c
>> +++ b/drivers/fpga/altera-pr-ip-core.c
>> @@ -201,11 +201,7 @@ EXPORT_SYMBOL_GPL(alt_pr_register);
>>  
>>  void alt_pr_unregister(struct device *dev)
>>  {
>> -	struct fpga_manager *mgr = dev_get_drvdata(dev);
>> -
>>  	dev_dbg(dev, "%s\n", __func__);
>> -
>> -	fpga_mgr_unregister(mgr);
>>  }
>>  EXPORT_SYMBOL_GPL(alt_pr_unregister);
>>  
>> -- 
>> 2.25.1




[Index of Archives]     [LM Sensors]     [Linux Sound]     [ALSA Users]     [ALSA Devel]     [Linux Audio Users]     [Linux Media]     [Kernel]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux