Linux Container Development
 help / color / mirror / Atom feed
From: Dan Smith <danms-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
To: Nathan Lynch <ntl-e+AXbWqSrlAAvxtiuMwx3w@public.gmane.org>
Cc: containers-qjLDD68F18O7TbgM5vRIOg@public.gmane.org
Subject: Re: [PATCH 3/3] c/r: define s390-specific checkpoint-restart code (v6)
Date: Wed, 25 Feb 2009 14:37:19 -0800	[thread overview]
Message-ID: <87ab8ata74.fsf@caffeine.danplanet.com> (raw)
In-Reply-To: <20090225162817.2003383c-4v5LP+xe+1byhTdZtsIeww@public.gmane.org> (Nathan Lynch's message of "Wed, 25 Feb 2009 16:28:17 -0600")

NL> In the powerpc implementation I was able to get away with
NL> returning zero, without writing dummy headers, for cases like
NL> this.

Right, as did we.  However, mktree.c expects to read a header in this
part of the stream.  The kernel expects what the kernel has written,
which is easy.  However, when writing something that needs to
interpret any platform's stream, I think it's easier if you don't have
a bunch of "optional" headers that you need to test for and maybe
handle (especially in the case of reading the stream over a socket or
the like).

>> +extern void cr_s390_regs(int op, struct cr_hdr_cpu *hh, struct task_struct *t);
>> +extern void cr_s390_mm(int op, struct cr_hdr_mm_context *hh,
>> +		       struct mm_struct *mm);

NL> These belong in a header, please...

Actually, I was hoping that Dave would stir up some conversation about
moving all of this back into a single file since we cut the line count
down so much with our evil macros :)

>> +	regs->psw.addr &= ~PSW_ADDR_INSN;
>> +	cr_s390_regs(CR_RST, hh, current);

NL> The PSW_ADDR_INSN bit in regs->psw.addr is cleared, and then
NL> regs-> psw.addr is overwritten by cr_s390_regs?

Yes, this is broken, thanks.  It is also an example of where the
macros won't work as nicely for us.  This is left over from Serge's
original code, where I believe he was attempting to avoid loading
anything into the PSW other than the instruction pointer bit.  A
trivial change to cr_s390_regs() will correct this.

Thanks!

-- 
Dan Smith
IBM Linux Technology Center
email: danms-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org

  parent reply	other threads:[~2009-02-25 22:37 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-25 18:12 [PATCH 0/3] c/r: Add s390 support Dan Smith
     [not found] ` <1235585529-806-1-git-send-email-danms-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2009-02-25 18:12   ` [PATCH 1/3] s390: Expose a constant for the number of words representing the CRs Dan Smith
2009-02-25 18:12   ` [PATCH 2/3] c/r: Add CR_COPY() macro (v2) Dan Smith
     [not found]     ` <1235585529-806-3-git-send-email-danms-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2009-02-25 22:08       ` Nathan Lynch
     [not found]         ` <20090225160841.4d727144-4v5LP+xe+1byhTdZtsIeww@public.gmane.org>
2009-02-25 22:21           ` Serge E. Hallyn
2009-02-25 22:23         ` Dan Smith
2009-02-25 18:12   ` [PATCH 3/3] c/r: define s390-specific checkpoint-restart code (v6) Dan Smith
     [not found]     ` <1235585529-806-4-git-send-email-danms-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2009-02-25 22:28       ` Nathan Lynch
     [not found]         ` <20090225162817.2003383c-4v5LP+xe+1byhTdZtsIeww@public.gmane.org>
2009-02-25 22:37           ` Dan Smith [this message]
2009-02-25 23:34           ` Nathan Lynch
2009-02-25 23:34           ` Serge E. Hallyn

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=87ab8ata74.fsf@caffeine.danplanet.com \
    --to=danms-r/jw6+rmf7hqt0dzr+alfa@public.gmane.org \
    --cc=containers-qjLDD68F18O7TbgM5vRIOg@public.gmane.org \
    --cc=ntl-e+AXbWqSrlAAvxtiuMwx3w@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