All of lore.kernel.org
 help / color / mirror / Atom feed
From: rubisher <rubisher@scarlet.be>
To: Grant Grundler <grundler@parisc-linux.org>
Cc: linux-parisc@vger.kernel.org
Subject: Re: iommu-helpers.h patch
Date: Fri, 28 Dec 2007 15:27:26 +0000	[thread overview]
Message-ID: <477515DE.7090403@scarlet.be> (raw)
In-Reply-To: <20071228075610.GD17782@colo.lackof.org>

Grant Grundler wrote:
> On Sat, Dec 22, 2007 at 01:45:45PM +0000, rubisher wrote:
>> Hello *,
>>
>> This seems to be missed a while ago ;-)
>>
>> --- drivers-parisc-iommu-helpers.h-git20071218	2007-12-21 
>> 19:02:38.000000000 +0000
>> +++ drivers-parisc-iommu-helpers.h-git20071218.new	2007-12-22 
>> 13:39:04.000000000 +0000
>> @@ -29,7 +29,7 @@
>>  		long size;
>>
>>  		DBG_RUN_SG(" %d : %08lx/%05x %08lx/%05x\n", nents,
>> -			   (unsigned long)sg_dma_address(startsg), cnt,
>> +			   (unsigned long)sg_dma_address(startsg), size,
> 
> Sorry - but this is wrong. "size" isn't initialized until later.
Agree with you: size is initialized later.

Anyway cnt variable was gone:
# grep cnt drivers/parisc/iommu-helpers.h
                            (unsigned long)sg_dma_address(startsg), cnt,

and imo it was with this patch:
<http://cvs.parisc-linux.org/linux-2.6/drivers/parisc/ccio-dma.c?r1=1.11&r2=1.12&makepatch=1&diff_format=u>

the interesting hunk's part was:
-		int cnt = sg_dma_len(startsg);
-		sg_dma_len(startsg) = 0;
+		unsigned long vaddr;
+		long size;

  		DBG_RUN_SG(" %d : %08lx/%05x %08lx/%05x\n", nents,
  			   (unsigned long)sg_dma_address(startsg), cnt,
  			   sg_virt_addr(startsg), startsg->length
  		);

+

(and make a kernel with DEBUG_CCIO_RUN_SG failed with an error at this place, so we need to patch ;-)

> "cnt" was the thing I needed/wanted dumped.
> 
So may be something like:

                 DBG_RUN_SG(" %d : %08lx/%05x %08lx/%05x\n", nents,
-                          (unsigned long)sg_dma_address(startsg), cnt,
+                          (unsigned long)sg_dma_address(startsg), sg_dma_len(startsg),
                            sg_virt_addr(startsg), startsg->length
                 );

Tx,
	r.

> cheers,
> grant
> 
>>  			   sg_virt_addr(startsg), startsg->length
>>  		);
>> === <> ===
>>
>> Cheers,
>> 	r.
>> -
>> To unsubscribe from this list: send the line "unsubscribe linux-parisc" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 
> 


  reply	other threads:[~2007-12-28 15:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-22 13:45 iommu-helpers.h patch rubisher
2007-12-28  7:56 ` Grant Grundler
2007-12-28 15:27   ` rubisher [this message]
2008-01-09  6:45     ` Grant Grundler

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=477515DE.7090403@scarlet.be \
    --to=rubisher@scarlet.be \
    --cc=grundler@parisc-linux.org \
    --cc=linux-parisc@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.