Message ID | 1496928465-25004-2-git-send-email-ulf.hansson@linaro.org |
---|---|
State | New |
Headers | show |
Series | mmc: core: Some trivial re-factoring and cleanups | expand |
On Thu, Jun 8, 2017 at 3:27 PM, Ulf Hansson <ulf.hansson@linaro.org> wrote: > The mmc_start|stop_bkops(), mmc_read_bkops_status() and mmc_interrupt_hpi() > functions are all used from within the mmc core module, thus there are no > need to use EXPORT_SYMBOL() for them, so let's remove it. > > Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> > @@ -428,7 +428,6 @@ void mmc_start_bkops(struct mmc_card *card, bool from_exception) > out: > mmc_release_host(card->host); > } > -EXPORT_SYMBOL(mmc_start_bkops); For this one, you can also mark it static, and remove the prototype in mmc_ops.h. It is only called from inside the same file! > int mmc_read_bkops_status(struct mmc_card *card) > { > @@ -887,7 +884,6 @@ int mmc_read_bkops_status(struct mmc_card *card) > kfree(ext_csd); > return 0; > } > -EXPORT_SYMBOL(mmc_read_bkops_status); Same for this, but you may have to move the function above the call site so it compiles. Yours, Linus Walleij -- To unsubscribe from this list: send the line "unsubscribe linux-mmc" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 9 June 2017 at 15:22, Linus Walleij <linus.walleij@linaro.org> wrote: > On Thu, Jun 8, 2017 at 3:27 PM, Ulf Hansson <ulf.hansson@linaro.org> wrote: > >> The mmc_start|stop_bkops(), mmc_read_bkops_status() and mmc_interrupt_hpi() >> functions are all used from within the mmc core module, thus there are no >> need to use EXPORT_SYMBOL() for them, so let's remove it. >> >> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> > >> @@ -428,7 +428,6 @@ void mmc_start_bkops(struct mmc_card *card, bool from_exception) >> out: >> mmc_release_host(card->host); >> } >> -EXPORT_SYMBOL(mmc_start_bkops); > > For this one, you can also mark it static, and remove the prototype in > mmc_ops.h. > > It is only called from inside the same file! Nope, used from core.c > >> int mmc_read_bkops_status(struct mmc_card *card) >> { >> @@ -887,7 +884,6 @@ int mmc_read_bkops_status(struct mmc_card *card) >> kfree(ext_csd); >> return 0; >> } >> -EXPORT_SYMBOL(mmc_read_bkops_status); > > Same for this, but you may have to move the function above > the call site so it compiles. Done in patch2. > > Yours, > Linus Walleij Kind regards Uffe -- To unsubscribe from this list: send the line "unsubscribe linux-mmc" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c index ad8caf4..d48be0b 100644 --- a/drivers/mmc/core/core.c +++ b/drivers/mmc/core/core.c @@ -428,7 +428,6 @@ void mmc_start_bkops(struct mmc_card *card, bool from_exception) out: mmc_release_host(card->host); } -EXPORT_SYMBOL(mmc_start_bkops); /* * mmc_wait_data_done() - done callback for data request @@ -811,7 +810,6 @@ int mmc_interrupt_hpi(struct mmc_card *card) mmc_release_host(card->host); return err; } -EXPORT_SYMBOL(mmc_interrupt_hpi); /** * mmc_wait_for_cmd - start a command and wait for completion @@ -869,7 +867,6 @@ int mmc_stop_bkops(struct mmc_card *card) return err; } -EXPORT_SYMBOL(mmc_stop_bkops); int mmc_read_bkops_status(struct mmc_card *card) { @@ -887,7 +884,6 @@ int mmc_read_bkops_status(struct mmc_card *card) kfree(ext_csd); return 0; } -EXPORT_SYMBOL(mmc_read_bkops_status); /** * mmc_set_data_timeout - set the timeout for a data command
The mmc_start|stop_bkops(), mmc_read_bkops_status() and mmc_interrupt_hpi() functions are all used from within the mmc core module, thus there are no need to use EXPORT_SYMBOL() for them, so let's remove it. Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> --- drivers/mmc/core/core.c | 4 ---- 1 file changed, 4 deletions(-) -- 2.7.4