suspend-to-ram: don't crash when kernel gets big

suspend-to-ram: don't crash when kernel gets big

Post by Martin Mare » Tue, 26 Nov 2002 01:00:08



Hi!

Quote:> +  pushl   $0                                              # Kill any dangerous flags
> +  popfl
> +  cli
> +  cld

Seems like you're trying to be 200% sure ;-)

                                Have a nice fortnight
--

Faculty of Math and Physics, Charles University, Prague, Czech Rep., Earth
First law of socio-genetics: Celibacy is not hereditary.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in

More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

 
 
 

suspend-to-ram: don't crash when kernel gets big

Post by Pavel Mache » Tue, 26 Nov 2002 01:00:12


Hi!

Quote:> > +     pushl   $0                                              # Kill any dangerous flags
> > +     popfl
> > +     cli
> > +     cld

> Seems like you're trying to be 200% sure ;-)

I was not sure if cli really *clears* it as name implies :-).

                                                        Pavel
--
Casualities in World Trade Center: ~3k dead inside the building,
cryptography in U.S.A. and free speech in Czech Republic.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in

More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

 
 
 

suspend-to-ram: don't crash when kernel gets big

Post by Randy.Dunla » Tue, 26 Nov 2002 01:40:13


| Hi!
|
| > > +   pushl   $0                      # Kill any dangerous flags
| > > +   popfl
| > > +   cli
| > > +   cld
| >
| > Seems like you're trying to be 200% sure ;-)
|
| I was not sure if cli really *clears* it as name implies :-).

Yes, as Martin suggested.  8;)

--
~Randy

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in

More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

 
 
 

suspend-to-ram: don't crash when kernel gets big

Post by Pavel Mache » Tue, 26 Nov 2002 01:50:04


Hi!

Quote:> | > > +      pushl   $0                      # Kill any dangerous flags
> | > > +      popfl
> | > > +      cli
> | > > +      cld
> | >
> | > Seems like you're trying to be 200% sure ;-)
> |
> | I was not sure if cli really *clears* it as name implies :-).

> Yes, as Martin suggested.  8;)

Actually, as following proves, I wanted to be *300%* sure ;-).

        cli
        cld

# We are now probably running at something like 0x0000 : 0x1000
        call here
here:
        pop      %bx
        subw    $(here-wakeup_start), %bx
        shrw    $4, %bx

        # setup data segment
        movw    %cs, %ax
        addw    %bx, %ax
        movw    %ax, %ds                                        # Make
ds:0 point to wakeup_start
        movw    %ax, %ss
        mov     $(wakeup_stack-wakeup_code), %sp                #
Private stack is needed for ASUS board
        movw    $0x0e00 + 'S', %fs:(0x12)

        pushl   $0                                              # Kill
any dangerous flags
        popfl
        cli
        cld

Fixed now. [Not that it matters.]
                                                        Pavel
--
Casualities in World Trade Center: ~3k dead inside the building,
cryptography in U.S.A. and free speech in Czech Republic.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in

More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/