public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
From: Bart Van Assche <bvanassche-HInyCGIudOg@public.gmane.org>
To: Upinder Malhi <umalhi-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org>,
	linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH for-next 7/9] IB/usnic: Fix printk format warnings
Date: Sat, 21 Dec 2013 11:07:03 +0100	[thread overview]
Message-ID: <52B56847.5070209@acm.org> (raw)
In-Reply-To: <1387298917-7365-8-git-send-email-umalhi-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org>

On 12/17/13 17:48, Upinder Malhi wrote:
> diff --git a/drivers/infiniband/hw/usnic/usnic_uiom.c b/drivers/infiniband/hw/usnic/usnic_uiom.c
> index 359897d..0477d70 100644
> --- a/drivers/infiniband/hw/usnic/usnic_uiom.c
> +++ b/drivers/infiniband/hw/usnic/usnic_uiom.c
> @@ -81,15 +81,16 @@ static void usnic_uiom_put_pages(struct list_head *chunk_list, int dirty)
>  	struct usnic_uiom_chunk *chunk, *tmp;
>  	struct page *page;
>  	int i;
> +	dma_addr_t pa;
>  
>  	list_for_each_entry_safe(chunk, tmp, chunk_list, list) {
>  		for (i = 0; i < chunk->nents; i++) {
>  			page = sg_page(&chunk->page_list[i]);
> +			pa = sg_phys(&chunk->page_list[i]);
>  			if (dirty)
>  				set_page_dirty_lock(page);
>  			put_page(page);
> -			usnic_dbg("pa: 0x%llx\n",
> -					sg_phys(&chunk->page_list[i]));
> +			usnic_dbg("pa: %pa\n", &pa);
>  		}
>  		kfree(chunk);
>  	}

Maybe I'm missing something, but is there any reason why in the above a
regular for-loop is used instead of for_each_sg() ?

Bart.

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

  parent reply	other threads:[~2013-12-21 10:07 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-17 16:48 [PATCH for-next 0/9] IB/usnic: Fix kbuild robot, sparse and smatch errs Upinder Malhi
     [not found] ` <1387298917-7365-1-git-send-email-umalhi-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org>
2013-12-17 16:48   ` [PATCH for-next 1/9] IB/usnic: Fix stack frame size exceed warnings Upinder Malhi
2013-12-17 16:48   ` [PATCH for-next 2/9] IB/usnic: Fix format not a string literal warnings Upinder Malhi
     [not found]     ` <1387298917-7365-3-git-send-email-umalhi-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org>
2013-12-21  9:58       ` Bart Van Assche
     [not found]         ` <52B56634.1020300-HInyCGIudOg@public.gmane.org>
2014-01-07 22:03           ` Upinder Malhi (umalhi)
2013-12-17 16:48   ` [PATCH for-next 3/9] IB/usnic: Make usNIC built depend on Intel IOMMU Upinder Malhi
2013-12-17 16:48   ` [PATCH for-next 4/9] IB/usnic: Fix error handling with IS_ERR_OR_NULL Upinder Malhi
     [not found]     ` <1387298917-7365-5-git-send-email-umalhi-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org>
2013-12-21 10:00       ` Bart Van Assche
     [not found]         ` <52B566A9.1080908-HInyCGIudOg@public.gmane.org>
2014-01-07 22:03           ` Upinder Malhi (umalhi)
     [not found]             ` <3A32A946-EB43-4609-A04A-3BB846C442DB-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org>
2014-01-08  0:11               ` Upinder Malhi (umalhi)
2013-12-17 16:48   ` [PATCH for-next 5/9] IB/usnic: Change BUG_ON to WARN_ON Upinder Malhi
     [not found]     ` <1387298917-7365-6-git-send-email-umalhi-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org>
2013-12-21 10:04       ` Bart Van Assche
     [not found]         ` <52B56799.2010306-HInyCGIudOg@public.gmane.org>
2014-01-07 22:05           ` Upinder Malhi (umalhi)
2013-12-17 16:48   ` [PATCH for-next 6/9] IB/usnic: Initialize all of the data returned to userspace Upinder Malhi
2013-12-17 16:48   ` [PATCH for-next 7/9] IB/usnic: Fix printk format warnings Upinder Malhi
     [not found]     ` <1387298917-7365-8-git-send-email-umalhi-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org>
2013-12-21 10:07       ` Bart Van Assche [this message]
     [not found]         ` <52B56847.5070209-HInyCGIudOg@public.gmane.org>
2014-01-07 22:07           ` Upinder Malhi (umalhi)
2013-12-17 16:48   ` [PATCH for-next 8/9] IB/usnic: Remove duplicate and unnecessary consts Upinder Malhi
2013-12-17 16:48   ` [PATCH for-next 9/9] IB/usnic: Fix sparse should be static warnings Upinder Malhi
     [not found]     ` <1387298917-7365-10-git-send-email-umalhi-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org>
2013-12-21 10:09       ` Bart Van Assche
     [not found]         ` <52B568CB.2070804-HInyCGIudOg@public.gmane.org>
2014-01-07 22:14           ` Upinder Malhi (umalhi)
2013-12-20 20:28   ` [PATCH for-next 0/9] IB/usnic: Fix kbuild robot, sparse and smatch errs Upinder Malhi (umalhi)

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=52B56847.5070209@acm.org \
    --to=bvanassche-hinycgiudog@public.gmane.org \
    --cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=umalhi-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org \
    /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