All of lore.kernel.org
 help / color / mirror / Atom feed
* dcbz-instruction on PPC405GP
@ 2003-07-11 14:23 Juergen Beisert
  2003-07-11 16:31 ` Tom Rini
  0 siblings, 1 reply; 3+ messages in thread
From: Juergen Beisert @ 2003-07-11 14:23 UTC (permalink / raw)
  To: linuxppc-embedded


Hello,

I want to speed up some data copy in my Linux driver and so I want to use the
dcbz-instruction.
I get the memory with a kmalloc()-call with GFP_KERNEL argument. After that I
call a small assembler routine that uses dcbz to set this memory to zero. I
am shure this memory starts at 32 byte boundary and ends at another 32 byte
boundary. But if I call the dcbz-instruction I get an alignment exception.
I have tried to test the "Write Trough" and "Caching Inhibit" bits for this
TLB, but I'm not shure that I have found the right one. I have called
get_pteptr() with the kmalloc() returned virtual address. Is this the right
way to get informations about this TLB? The returned value seems ok (caching
enabled and write back, if Linux uses the same bit positions like the 405GP
manual).
With caching enabled and write back the dcbz-instruction should work (that's
what I have read in the manual). Right?

I have seen the alignment exception while BDI is running for debugging. If I
start my system without a connected BDI it hangs forever.

Is the dcbz-instruction broken on 405GP?

Best regards
Juergen Beisert
--
*********************************
Fa. EuroDesign
embedded technologies GmbH
Waldstr. 4a
85414 Kirchdorf a.d. Amper/Germany

Tel: +49/8166/99495-77
Fax: +49/8166/99495-81

EMAIL: jbeisert@eurodsn.de
Web: http://www.eurodsn.de
*********************************

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: dcbz-instruction on PPC405GP
  2003-07-11 14:23 dcbz-instruction on PPC405GP Juergen Beisert
@ 2003-07-11 16:31 ` Tom Rini
  2003-07-14  7:09   ` Juergen Beisert
  0 siblings, 1 reply; 3+ messages in thread
From: Tom Rini @ 2003-07-11 16:31 UTC (permalink / raw)
  To: Juergen Beisert; +Cc: linuxppc-embedded


On Fri, Jul 11, 2003 at 04:23:45PM +0200, Juergen Beisert wrote:

> I want to speed up some data copy in my Linux driver and so I want to use the
> dcbz-instruction.
> I get the memory with a kmalloc()-call with GFP_KERNEL argument. After that I
> call a small assembler routine that uses dcbz to set this memory to zero. I
> am shure this memory starts at 32 byte boundary and ends at another 32 byte
> boundary. But if I call the dcbz-instruction I get an alignment exception.
> I have tried to test the "Write Trough" and "Caching Inhibit" bits for this
> TLB, but I'm not shure that I have found the right one. I have called
> get_pteptr() with the kmalloc() returned virtual address. Is this the right
> way to get informations about this TLB? The returned value seems ok (caching
> enabled and write back, if Linux uses the same bit positions like the 405GP
> manual).
> With caching enabled and write back the dcbz-instruction should work (that's
> what I have read in the manual). Right?

Why are you not calling memset on this region instead?

--
Tom Rini
http://gate.crashing.org/~trini/

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: dcbz-instruction on PPC405GP
  2003-07-11 16:31 ` Tom Rini
@ 2003-07-14  7:09   ` Juergen Beisert
  0 siblings, 0 replies; 3+ messages in thread
From: Juergen Beisert @ 2003-07-14  7:09 UTC (permalink / raw)
  To: Tom Rini; +Cc: linuxppc-embedded


Am Freitag, 11. Juli 2003 18:31 schrieb Tom Rini:
> On Fri, Jul 11, 2003 at 04:23:45PM +0200, Juergen Beisert wrote:
>
> Why are you not calling memset on this region instead?

"memset" only uses simple store instructions. But besides the "memset"
function if found "cacheable_memzero". Seems in my own code is a bug, because
"cacheable_memzero" runs with "dcbz" on my data buffer without an error.

Thanks for your suggestion
-- JB

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2003-07-14  7:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-11 14:23 dcbz-instruction on PPC405GP Juergen Beisert
2003-07-11 16:31 ` Tom Rini
2003-07-14  7:09   ` Juergen Beisert

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.