[K42-discussion] Problem with changing FairLock class

Bryan S Rosenburg rosnbrg at us.ibm.com
Thu Dec 22 00:35:56 EST 2005


I checked, and I don't think Marc's concern is the issue here.  The 
assembler code he's referring to is contained in inline asm statements 
that, as far as I can tell, reference the lock fields properly wherever 
they happen to be.

Alex, you say you changed the size of spinlock_t to match your new 
FairBLock.  I assume you rebuilt your Linux modules after doing so?

The only other possible problem I found (without actually trying to 
reproduce your experiment) is the k42_rtas_t struct in 
kitchsrc/os/kernel/bilge/arch/powerpc/BootInfo.H:

struct k42_rtas_t {
        uval64 entry;           /* physical address pointer */
        uval64 base;            /* physical address pointer */
        uval64 size;
        //spinlock_t lock;
        uval64 lock[2];

        fill32;
        struct device_node *dev;        /* virtual address pointer */
};

This is ugly, but maybe expanding the lock field there is needed.

Your invalid memory access is happening early in Linux module 
initialization, so I'm guessing there's a size mismatch between the Linux 
stuff and K42, probably because something didn't get rebuilt properly.

- Bryan




Marc Auslander/Watson/Contr/IBM at IBMUS 
Sent by: k42-discussion-bounces at ozlabs.org
12/20/2005 08:02 PM

To
Alex Depoutovitch <siroko at gmail.com>
cc
k42-discussion-bounces at ozlabs.org, k42-discussion at ozlabs.org
Subject
Re: [K42-discussion] Problem with changing FairLock class







IIRC, fairlock has machine dependent assembler code that actually 
implements it.  You need to make sure that the assembler code is 
consistent with your code.  I'm not sure this is the problem but you need 
to check. 

Marc Auslander <Marc_Auslander at us.ibm.com> 914 945-4346 (Fax x4282) 


Alex Depoutovitch <siroko at gmail.com> 
Sent by: k42-discussion-bounces at ozlabs.org 
12/20/2005 06:58 PM 


To
k42-discussion at ozlabs.org 
cc

Subject
[K42-discussion] Problem with changing FairLock class








Hi,
I tired to add data member to FairLock class. I changed size of
spinlock_t structure accordingly so that they have the same size.
But after I have done it K42 crashes during boot process with:
---
.......
NET: Registered protocol family 16
/lewis/d/d1/depout/k42/kitchsrc/os/kernel/proc/ProcessShared.C,255:
Invalid memory access: processID 0x0 addr 0x0, type
-6917529026567294926
GDB got trap: Data Storage Interrupt
vector=0x300, sr=0xa00000004000b032, pc=0x0 lr=0xc000000002338020
Kernel Connecting to GDB via thinwire channel
-----

Connecting with gdb does not help much as stack is corrupted and bt
command returns:
--
(gdb) bt
#0  0x0000000000000000 in ?? ()
--

Could anybody please tell me how to change size of FairLock structure
in a right way? Any suggestions are really appreciated.

Thank you,

Alex
_______________________________________________
K42-discussion mailing list
K42-discussion at ozlabs.org
https://ozlabs.org/mailman/listinfo/k42-discussion
_______________________________________________
K42-discussion mailing list
K42-discussion at ozlabs.org
https://ozlabs.org/mailman/listinfo/k42-discussion

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://ozlabs.org/pipermail/k42-discussion/attachments/20051221/0547454a/attachment.htm 


More information about the K42-discussion mailing list