linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Michael Neuling <mikey@neuling.org>
To: Milton Miller <miltonm@bga.com>
Cc: linuxppc-dev@ozlabs.org, paulus@samba.org, anton@samba.org
Subject: Re: [PATCH] SLB shadow buffer
Date: Tue, 08 Aug 2006 14:21:05 +1000	[thread overview]
Message-ID: <20060808042106.4379E679FD@ozlabs.org> (raw)
In-Reply-To: <11154999753625558ec1.596516649.miltonm@bga.com>

> > +#define SHADOW_SLB_BOLTED_STACK_ESID \
> > +		(SLBSHADOW_SAVEAREA + 0x10*(SLB_NUM_BOLTED-1))
> > +#define SHADOW_SLB_BOLTED_STACK_VSID \
> > +		(SLBSHADOW_SAVEAREA + 0x10*(SLB_NUM_BOLTED-1) + 8)
> > +
> Still a bit of magic size, but not likely to change.
> 
> Maybe an expicit define for the slot?

Arrh nice, I can do this all in asm-offsets.  Much less magic.

> > +	/* Update the last bolted SLB */
> > +	ld	r9,PACA_SLBSHADOWPTR(r13)
> > + 	li	r12,0
> > +  	std	r12,SHADOW_SLB_BOLTED_STACK_ESID(r9) /* Clear ESID */
> > +	std	r7,SHADOW_SLB_BOLTED_STACK_VSID(r9)  /* Save VSID */
> > + 	std	r0,SHADOW_SLB_BOLTED_STACK_ESID(r9)  /* Save ESID */
> > +
> 
>  Still some leading spaces hiding

Yep... oops.  

> 
> >  Index: linux-2.6-ozlabs/include/asm-powerpc/lppaca.h
> 
> > @@ -133,5 +135,22 @@ struct > > > lppaca {
> >  
> >  extern struct lppaca lppaca[];
> >  
> > +/*
> > + * SLB shadow buffer structure as defined in the PAPR.  The save_area
> > + * contains adjacent ESID and VSID pairs for each shadowed SLB.  The
> > + * ESID is stored in the lower 64bits, then the VSID.
> > + */
> > +struct slb_shadow {
> > +	u32	persistent;		// Number of persistent SLBs	x00-x03
> > +	u32	buffer_length;		// Total shadow buffer length	x04-x07
> > +	u64	reserved;		// Alignment			x08-x0f
> > +	struct	{
> > +		u64     esid;
> > +		u64	vsid;
> > +	} save_area[SLB_NUM_BOLTED];	//				x10-x40
> > +} ____cacheline_aligned;
> > +
> 
> C comments ... or in the separate cleanup patch

I think I'll post a full lppaca cleanup patch in a bit.  

> > +extern struct slb_shadow slb_shadow[];
> > +
> >  #endif /* __KERNEL__ */
> >  #endif /* _ASM_POWERPC_LPPACA_H */
> > Index: linux-2.6-ozlabs/include/asm-powerpc/paca.h
> > ===================================================================
> > 
> >  	/* accumulated system TB ticks */
> >  	u64 startpurr;			/* PURR/TB value snapshot */
> > +
> > +	struct slb_shadow *slb_shadow_ptr;
> >  };
>  
> Do we need the extra line?  (I haven't looked at the result)

They are broken into logical groups, so no.

Updated patch to come.

Michael

  reply	other threads:[~2006-08-08  4:21 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-08  1:15 [PATCH] SLB shadow buffer Milton Miller
2006-08-08  4:21 ` Michael Neuling [this message]
  -- strict thread matches above, loose matches on Subject: below --
2006-08-08  4:29 Michael Neuling
2006-08-07  6:19 Michael Neuling
2006-08-05 21:18 Milton Miller
2006-08-06  1:27 ` Michael Neuling
2006-08-05  5:56 Milton Miller
2006-08-07  5:55 ` Michael Neuling
2006-08-04  5:53 Michael Neuling
2006-08-05 12:45 ` Christoph Hellwig
2006-08-09 11:22   ` Benjamin Herrenschmidt
2006-08-09 13:01     ` Segher Boessenkool

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=20060808042106.4379E679FD@ozlabs.org \
    --to=mikey@neuling.org \
    --cc=anton@samba.org \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=miltonm@bga.com \
    --cc=paulus@samba.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;
as well as URLs for NNTP newsgroup(s).