Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=6faf4444f2445b068a4f75a86ae81b104c0eed2c
Commit:     6faf4444f2445b068a4f75a86ae81b104c0eed2c
Parent:     dd401e2b9250e3bb07ef388ddccbbf80aa106fc7
Author:     Heiko Carstens <[EMAIL PROTECTED]>
AuthorDate: Tue Jan 9 10:18:41 2007 +0100
Committer:  Martin Schwidefsky <[EMAIL PROTECTED]>
CommitDate: Tue Jan 9 10:18:41 2007 +0100

    [S390] cio: use barrier() in stsch_reset.
    
    Use barrier() in stsch_reset() instead of duplicating the stsch()
    inline assembly and adding "memory" to the clobberlist.
    Pointed out by Chuck Ebbert.
    
    Real fix would be to add a fixup section to the stsch() and extend the
    basic program check handler so it searches the exception tables in case
    of a program check.
    
    Signed-off-by: Heiko Carstens <[EMAIL PROTECTED]>
    Signed-off-by: Martin Schwidefsky <[EMAIL PROTECTED]>
---
 drivers/s390/cio/cio.c |   12 ++++--------
 1 files changed, 4 insertions(+), 8 deletions(-)

diff --git a/drivers/s390/cio/cio.c b/drivers/s390/cio/cio.c
index b471ac4..ae1bf23 100644
--- a/drivers/s390/cio/cio.c
+++ b/drivers/s390/cio/cio.c
@@ -880,19 +880,15 @@ static void cio_reset_pgm_check_handler(void)
 static int stsch_reset(struct subchannel_id schid, volatile struct schib *addr)
 {
        int rc;
-       register struct subchannel_id reg1 asm ("1") = schid;
 
        pgm_check_occured = 0;
        s390_reset_pgm_handler = cio_reset_pgm_check_handler;
+       rc = stsch(schid, addr);
+       s390_reset_pgm_handler = NULL;
 
-       asm volatile(
-               "       stsch   0(%2)\n"
-               "       ipm     %0\n"
-               "       srl     %0,28"
-               : "=d" (rc)
-               : "d" (reg1), "a" (addr), "m" (*addr) : "memory", "cc");
+       /* The program check handler could have changed pgm_check_occured */
+       barrier();
 
-       s390_reset_pgm_handler = NULL;
        if (pgm_check_occured)
                return -EIO;
        else
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to