Re: [PATCH v1 5/8] scsi: ufs: creates wrapper functions for vops
From: Akinobu Mita
Date: Wed Aug 19 2015 - 08:19:14 EST
2015-08-16 19:14 GMT+09:00 Yaniv Gardi <ygardi@xxxxxxxxxxxxxx>:
> In order to simplify the code a set of wrapper functions is created
> to test and call each of the variant operations.
>
> Signed-off-by: Yaniv Gardi <ygardi@xxxxxxxxxxxxxx>
>
> ---
> drivers/scsi/ufs/ufs-qcom.c | 3 +-
> drivers/scsi/ufs/ufshcd.c | 104 +++++++++++++++++---------------------------
> drivers/scsi/ufs/ufshcd.h | 98 +++++++++++++++++++++++++++++++++++++++++
> 3 files changed, 138 insertions(+), 67 deletions(-)
>
> diff --git a/drivers/scsi/ufs/ufs-qcom.c b/drivers/scsi/ufs/ufs-qcom.c
> index 64c54b7..a6b7e10 100644
> --- a/drivers/scsi/ufs/ufs-qcom.c
> +++ b/drivers/scsi/ufs/ufs-qcom.c
> @@ -1036,7 +1036,7 @@ void ufs_qcom_clk_scale_notify(struct ufs_hba *hba)
> * The variant operations configure the necessary controller and PHY
> * handshake during initialization.
> */
> -static const struct ufs_hba_variant_ops ufs_hba_qcom_vops = {
> +static struct ufs_hba_variant_ops ufs_hba_qcom_vops = {
Why do we need to drop 'const'?
> .name = "qcom",
> .init = ufs_qcom_init,
> .exit = ufs_qcom_exit,
> @@ -1049,6 +1049,5 @@ static const struct ufs_hba_variant_ops ufs_hba_qcom_vops = {
> .suspend = ufs_qcom_suspend,
> .resume = ufs_qcom_resume,
> };
> -EXPORT_SYMBOL(ufs_hba_qcom_vops);
In patch 8, ufs_hba_qcom_vops is exported again...
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/