Skip to contentSkip to conversation

Stack size

DISCUSSION Breno 8 participants 10 messages Sep 12, 2003 – Sep 15, 2003 SCSI

lore
Share & tools
lore

Breno

author
#0 lore raw

What happen when stack increase more than 8mb ?

att
Breno

#1 lore raw

[Hey, any chance you could join us in September? ;-) "Date: Sun, 12 Oct
2003 13:35:33 +0100"]

Quoted 1 line · * Breno ([email protected]) wrote:

What happen when stack increase more than 8mb ?

Memory corruption.
-chris

Signature · 1 line
Linux Security Modules     http://lsm.immunix.org     http://lsm.bkbits.net
author
#2 lore raw

Is there a test in kernel to know how much memory is consumed by stack ?

Breno
----- Original Message -----
From: "Chris Wright" <[email protected]>
To: "Breno" <[email protected]>
Cc: "Kernel List" <[email protected]>
Sent: Friday, September 12, 2003 2:41 PM
Subject: Re: Stack size

Quoted 10 lines

[Hey, any chance you could join us in September? ;-) "Date: Sun, 12 Oct
2003 13:35:33 +0100"]

Quoted 1 line · * Breno ([email protected]) wrote:

What happen when stack increase more than 8mb ?

Memory corruption.
-chris
--
Linux Security Modules http://lsm.immunix.org

http://lsm.bkbits.net

Quoted 5 lines

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

#3 lore raw
Quoted 1 line · * Breno ([email protected]) wrote:

Is there a test in kernel to know how much memory is consumed by stack ?

Have you looked at the CONFIG_DEBUG_STACKOVERFLOW code? thanks,
-chris

Signature · 1 line
Linux Security Modules     http://lsm.immunix.org     http://lsm.bkbits.net
#4 lore raw
In reply to Chris Wright
Quoted 5 lines · Chris Wright
Quoted 1 line · * Breno ([email protected]) wrote:

Is there a test in kernel to know how much memory is consumed by stack ?

Have you looked at the CONFIG_DEBUG_STACKOVERFLOW code?

Just a band aid, not more. If you want to be sure, poison the stack on fork and check the poison on exit.

Jörn

Signature · 2 lines
Do not stop an army on its way home.
-- Sun Tzu
#5 lore raw
In reply to Chris Wright

On Sun, 2003-10-12 at 08:35, Breno wrote:

       ^^^^^^^^^^^^^^^^^^^^   
Quoted 2 lines · Chris Wright

[Hey, any chance you could join us in September? ;-) "Date: Sun, 12 Oct
2003 13:35:33 +0100"]

Breno:

Carpe diem! Live the present!

Signature · 1 line
matías <-> http://matiu.com.ar
#7 lore raw
In reply to Breno

Breno, Sun, Oct 12, 2003 14:35:33 +0200:

Quoted 1 line

What happen when stack increase more than 8mb ?

in the kernel or in a user program?

In user program - probably nothing.

#8 lore raw

Exemple of code for cmd " scsi start "

In reply to Breno

Hello,
I search an exemple in C for send a command to a disk, the scsi command
i need is a start command.
Where can i find a exemple with source code.

cdt
philipp

#9 lore raw

Re: Exemple of code for cmd " scsi start "

Quoted 5 lines · phil

Hello,
I search an exemple in C for send a command to a disk, the scsi command
i need is a start command.
Where can i find a exemple with source code.

For user level code:

http://www.torque.net/sg/#Utilities:%20sg_utils%20and%20sg3_utils

Check out sg_start.c.

Kernel code - drivers/kernel/sd.c uses START_STOP, other code in sd.c and scsi_scan.c use various SCSI commands.

-- Patrick Mansfield