virtualization.lists.linux-foundation.org archive mirror
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: Srujana Challa <schalla@marvell.com>
Cc: virtualization@lists.linux.dev, jasowang@redhat.com,
	dan.carpenter@linaro.org, xuanzhuo@linux.alibaba.com,
	eperezma@redhat.com, ndabilpuram@marvell.com,
	vattunuru@marvell.com, kernel test robot <lkp@intel.com>
Subject: Re: [PATCH] vdpa/octeon_ep: Fix format specifier for pointers in debug messages
Date: Mon, 16 Sep 2024 13:41:53 -0400	[thread overview]
Message-ID: <20240916134107-mutt-send-email-mst@kernel.org> (raw)
In-Reply-To: <20240916162255.677774-1-schalla@marvell.com>

On Mon, Sep 16, 2024 at 09:52:55PM +0530, Srujana Challa wrote:
> Updates the debug messages in octep_vdpa_hw.c to use the %p format
> specifier for pointers instead of casting them to u64.
> 
> Fixes smatch warning:
> octep_hw_caps_read() warn: argument 3 to %016llx specifier is cast
> from pointer
> 
> Fixes: 8b6c724cdab8 ("virtio: vdpa: vDPA driver for Marvell OCTEON DPU devices")
> 
> Reported-by: kernel test robot <lkp@intel.com>
> Reported-by: Dan Carpenter <dan.carpenter@linaro.org>
> Closes:https://urldefense.proofpoint.com/v2/url?u=https-3A__lore.kernel.org_r_202409160431.bRhZWhiU-2Dlkp-40intel.com_&d=DwIBAg&c=nKjWec2b6R0mOyPaz7xtfQ&r=Fj4OoD5hcKFpANhTWdwQzjT1Jpf7veC5263T47JVpnc&m=qyhlWh2lFE3SPFpB_eJ0K1RFMa5f-kcNChFHkCARDCXIkzMk__3sqspP_K7KGxaj&s=fMvS62XMmi5HESJuL9v7FX3c8RSzKCq7JM6Khcof4vM&e=

Don't do this please, just normal URLs.
https://lore.kernel.org/all/202409160431.bRhZWhiU-lkp@intel.com/

in this case.

> Signed-off-by: Srujana Challa <schalla@marvell.com>
> ---
>  drivers/vdpa/octeon_ep/octep_vdpa_hw.c | 12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/vdpa/octeon_ep/octep_vdpa_hw.c b/drivers/vdpa/octeon_ep/octep_vdpa_hw.c
> index 11bd76ae18cf..1d4767b33315 100644
> --- a/drivers/vdpa/octeon_ep/octep_vdpa_hw.c
> +++ b/drivers/vdpa/octeon_ep/octep_vdpa_hw.c
> @@ -475,11 +475,11 @@ int octep_hw_caps_read(struct octep_hw *oct_hw, struct pci_dev *pdev)
>  		dev_err(dev, "Incomplete PCI capabilities");
>  		return -EIO;
>  	}
> -	dev_info(dev, "common cfg mapped at: 0x%016llx\n", (u64)(uintptr_t)oct_hw->common_cfg);
> -	dev_info(dev, "device cfg mapped at: 0x%016llx\n", (u64)(uintptr_t)oct_hw->dev_cfg);
> -	dev_info(dev, "isr cfg mapped at: 0x%016llx\n", (u64)(uintptr_t)oct_hw->isr);
> -	dev_info(dev, "notify base: 0x%016llx, notify off multiplier: %u\n",
> -		 (u64)(uintptr_t)oct_hw->notify_base, oct_hw->notify_off_multiplier);
> +	dev_info(dev, "common cfg mapped at: %p\n", oct_hw->common_cfg);
> +	dev_info(dev, "device cfg mapped at: %p\n", oct_hw->dev_cfg);
> +	dev_info(dev, "isr cfg mapped at: %p\n", oct_hw->isr);
> +	dev_info(dev, "notify base: %p, notify off multiplier: %u\n",
> +		 oct_hw->notify_base, oct_hw->notify_off_multiplier);
>  
>  	oct_hw->config_size = octep_get_config_size(oct_hw);
>  	oct_hw->features = octep_hw_get_dev_features(oct_hw);
> @@ -511,7 +511,7 @@ int octep_hw_caps_read(struct octep_hw *oct_hw, struct pci_dev *pdev)
>  	}
>  	mbox = octep_get_mbox(oct_hw);
>  	octep_mbox_init(mbox);
> -	dev_info(dev, "mbox mapped at: 0x%016llx\n", (u64)(uintptr_t)mbox);
> +	dev_info(dev, "mbox mapped at: %p\n", mbox);
>  
>  	return 0;
>  }
> -- 
> 2.25.1


  reply	other threads:[~2024-09-16 17:42 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-16 16:22 [PATCH] vdpa/octeon_ep: Fix format specifier for pointers in debug messages Srujana Challa
2024-09-16 17:41 ` Michael S. Tsirkin [this message]
2024-09-16 17:43 ` Michael S. Tsirkin
2024-09-17  5:59   ` [EXTERNAL] " Srujana Challa
2024-09-17 12:32     ` Srujana Challa
2024-09-18 14:43     ` Michael S. Tsirkin
2024-09-18 16:25       ` Srujana Challa
2024-09-16 17:43 ` Michael S. Tsirkin
2024-09-18  9:34 ` Dan Carpenter

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=20240916134107-mutt-send-email-mst@kernel.org \
    --to=mst@redhat.com \
    --cc=dan.carpenter@linaro.org \
    --cc=eperezma@redhat.com \
    --cc=jasowang@redhat.com \
    --cc=lkp@intel.com \
    --cc=ndabilpuram@marvell.com \
    --cc=schalla@marvell.com \
    --cc=vattunuru@marvell.com \
    --cc=virtualization@lists.linux.dev \
    --cc=xuanzhuo@linux.alibaba.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).