Linux-Development-Sys Digest #50, Volume #8 Thu, 27 Jul 00 23:13:16 EDT
Contents:
contents of sk_buff->data ([EMAIL PROTECTED])
Re: A good IDE ("Jan Schaumann")
Re: where is "clear" source?? (Iwo Mergler)
Intel OR840 Hang (Eric Kasten)
Re: Want to know update web site for updated valid kernel commands (Rick Ellis)
test (Johan Kullstam)
Re: [ANN] Beta testing of CW for Linux on Intel and PowerPC (bill davidsen)
Re: A good IDE (bill davidsen)
Re: Reproducable crashing linux-2.2.16 (bill davidsen)
Re: Warning! -- SONY SUBSTANDARD SERVICE (Eric Lemar)
register_symtab() (Sean)
Re: A good IDE (alex)
SIGSEGV during interruptible_sleep_on (Wolfram Faul)
Re: Asynchronous I/O ("Norm Dresner")
Re: register_symtab() ("Norm Dresner")
Re: SIGSEGV during interruptible_sleep_on (Linus Torvalds)
Re: JNI peer classes ([EMAIL PROTECTED])
major difference between uCLinux 2.0 and 2.4? (Yew Fai, Wong)
Re: Setting Serial-Port Status lines (Jonathan Lundell)
function size (tye4)
Re: test (phil hunt)
Tracing fork system calls. (Tim Muir)
----------------------------------------------------------------------------
From: [EMAIL PROTECTED]
Subject: contents of sk_buff->data
Date: Thu, 27 Jul 2000 13:38:33 GMT
Hi,
I have a module receives sk_buffs straight from ethernet-devices. Now
I'm trying to write the contents of the data-part of an sk_buff to
user-space. So I have :
struct sk_buff *someskb; and i'm using put_user(blahblah) to copy
everything from someskb->data until someskb->tail to some userspace
buffer. After analyzing the output though I seem to get nothing but
rubbish. Someone having any clues ?
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
From: "Jan Schaumann" <[EMAIL PROTECTED]>
Subject: Re: A good IDE
Crossposted-To: comp.os.linux.development.apps,comp.os.linux.hardware
Date: Thu, 27 Jul 2000 11:06:56 -0400
On 27 Jul 2000 04:57:40 GMT, [EMAIL PROTECTED] (cLIeNUX user) wrote:
> [EMAIL PROTECTED]
>>[EMAIL PROTECTED] (cLIeNUX user) writes:
>>
>>> [EMAIL PROTECTED]
>>> >[EMAIL PROTECTED] (cLIeNUX user) writes:
>>> >
>>> >>>Well, emacs can do that too. Even better, you can do M-x compile,
>>> >>>and C-x ` (that's a backquote) takes you to the next error in the
>>> >>>output, opening files as necessary.
>>> >
>>> >>IFF your code is all set up right for emacs. Mine isn't.
>>> >
>>> >How can your code be setup wrong for emacs? You could have a
>>> >different formatting, but it should be not problem to turn off emacs
>>> >auto formatting option, or to customize them to suit your needs.
>>>
>>>
>>> I use sh scripts instead of make. The script is typically called
>>> "build", and there may be others for what would usually be make
>>> targets like
>>> "clean".
>>
>>you can adjust the compile-command.
>>
>>in your .emacs, put
>>
>>;; compile command
>>(setq compile-command "build")
>>
>
>
> Thanks, but I'll just type build in the shell.
You could,of course, call a shell from inside of emacs (M+!, IIRC)... ;-)
Fup2 comp.os.linux.development.apps
-Jan
--
Jan Schaumann <http://www.netmeister.org>
What good is an obscenity trial except to popularize literature?
-- Nero Wolfe, "The League of Frightened Men"
------------------------------
From: Iwo Mergler <[EMAIL PROTECTED]>
Subject: Re: where is "clear" source??
Date: Thu, 27 Jul 2000 14:25:19 GMT
Thomas Dickey wrote:
>
> Zirong Wang <[EMAIL PROTECTED]> wrote:
> > Hi dan,
>
> > try printf(stdout, "\033\143");
>
> resetting the terminal is a bad idea (a real vt100 would disconnect)
>
> --
> Thomas E. Dickey <[EMAIL PROTECTED]> <[EMAIL PROTECTED]>
> http://dickey.his.com
> ftp://dickey.his.com
printf(stdout,"\0x1B[2J") ?
------------------------------
From: Eric Kasten <[EMAIL PROTECTED]>
Subject: Intel OR840 Hang
Date: 27 Jul 2000 15:20:22 GMT
Hi,
Has anyone managed to get linux to boot on an Intel OR840 motherboard.
This is a dual processor (PIII) with dual bus RDRAM. More info
can be found at: http://developer.intel.com/design/wrkstn/OR840/index.htm
Using either a 2.2.16 kernel or a 2.4.0-test4 kernel, the boot will
hang while "Probing PCI hardware". If you disable PCI support
entirely in the linux kernel build, than it doesn't hang.
(not very useful without the PCI bus, but it doesn't hang). I've also
tried direct vs BIOS access using the 2.2.16 kernel -- still no go
either way. Compiled the kernels both with and without SMP support
-- didn't help.
The kernel says that this is:
PCI: PCI BIOS revision 2.10 entry at 0xfdb91, last bus=2
PCI: Using configuration type 1
PCI: Probing PCI hardware
And that's were everything stops. Any ideas/solutions?
Thanks.
--
Eric Kasten
[EMAIL PROTECTED]
------------------------------
From: [EMAIL PROTECTED] (Rick Ellis)
Subject: Re: Want to know update web site for updated valid kernel commands
Date: 27 Jul 2000 16:46:49 GMT
In article <[EMAIL PROTECTED]>,
Rob Morris <[EMAIL PROTECTED]> wrote:
>We have been writing a simple character device driver. We have been
>using memcpy_tofs command, which apparently is not defined under kernel
>version 2.2.14. I am new to the area and discovered there was a huge
>change in the kernel commands when version 2.1 came out. The long and
>the short of it is we FINALLY figured this out and are now using the
>appropriate command copy_to_user command.
>
>My question is......does anyone know a good web source for the nitty
>gritty details of all the changes to the available kernel commands?
This might help:
http://www.atnf.csiro.au/~rgooch/linux/docs/porting-to-2.2.html
--
http://www.fnet.net/~ellis/photo/linux.html
------------------------------
From: Johan Kullstam <[EMAIL PROTECTED]>
Subject: test
Date: 27 Jul 2000 13:30:29 -0400
please ignore. i don't have alt.test and my nntp server has been
giving grief.
--
J o h a n K u l l s t a m
[[EMAIL PROTECTED]]
sysengr
------------------------------
From: [EMAIL PROTECTED] (bill davidsen)
Crossposted-To: comp.os.linux.powerpc
Subject: Re: [ANN] Beta testing of CW for Linux on Intel and PowerPC
Date: 27 Jul 2000 18:09:05 GMT
In article <gTtf5.48358$[EMAIL PROTECTED]>,
<[EMAIL PROTECTED]> wrote:
| In comp.os.linux.development.system MWRon <[EMAIL PROTECTED]> wrote:
| > We got it and I plan to post in the Announce group, there is now a
| > codewarrior.linux newsgroup. Ask your ISP to add it (and the entire
| > codewarrior.* hierarchy) to your service.
|
| As we continue to drift 1k miles off-topic, I feel obliged to point
| out that poluting the hierarchy is an even worse solution than most.
Why do you feel that a linux group in the codewarrior hierarchy is
poluting it? It's their hierarchy, isn't it?
--
bill davidsen <[EMAIL PROTECTED]> CTO, TMR Associates, Inc
There are those who make things happen, those who watch things happen,
and those who wonder what happened.
-- idea from _Pickles_
------------------------------
From: [EMAIL PROTECTED] (bill davidsen)
Crossposted-To: comp.os.linux.development.apps,comp.os.linux.hardware
Subject: Re: A good IDE
Date: 27 Jul 2000 18:19:53 GMT
In article <8ljhsr$vam$[EMAIL PROTECTED]>, cLIeNUX user <[EMAIL PROTECTED]> wrote:
| >If by '+' you mean compile, parse errors and edit, then joe can do that
| >quite easily.
|
| No, I mean
|
| pico +210 bletch.c
|
|
| where 210 was the line gcc reported a fatal error on.
IIRC the 'elvis' vi clone does what you want, assuming that you have a
makefile in the current directory. It runs make and jumps you through
all the files reporting errors. Under X, that is, never tried it any
other way.
--
bill davidsen <[EMAIL PROTECTED]> CTO, TMR Associates, Inc
There are those who make things happen, those who watch things happen,
and those who wonder what happened.
-- idea from _Pickles_
------------------------------
From: [EMAIL PROTECTED] (bill davidsen)
Subject: Re: Reproducable crashing linux-2.2.16
Date: 27 Jul 2000 18:30:27 GMT
In article <8ljr9g$f73$[EMAIL PROTECTED]>,
Martin Kahlert <[EMAIL PROTECTED]> wrote:
| Hi!
| Could anybody check this (it would be best *not* to try it on a
| production machine...)
|
| cat crash.c
| #include <alloca.h>
| #include <string.h>
| #include <stdlib.h>
|
| int main(int argc,char *argv[])
| {
| if(argc==2)
| {
| unsigned int n = 1 << atoi(argv[1]);
| char *b = alloca(n);
|
| if(b)
| memset(b,0,n);
| }
|
| return 0;
| }
|
| gcc -o crash crash.c
| ./crash 30
|
| Will reproducable crash my linux machine.
Sounds as if you have played with the stack size limit, alloca should
happily fail unless you do. And you need to be root to up the limit, and
you need memory overcommit on I believe, etc. In other words, it
shouldn't do much on a properly configured machine, and it shouldn't
crash in any case, but it will get really slow as it pages.
Should be able to just ^C out.
--
bill davidsen <[EMAIL PROTECTED]> CTO, TMR Associates, Inc
There are those who make things happen, those who watch things happen,
and those who wonder what happened.
-- idea from _Pickles_
------------------------------
From: Eric Lemar <[EMAIL PROTECTED]>
Subject: Re: Warning! -- SONY SUBSTANDARD SERVICE
Date: Thu, 27 Jul 2000 18:33:46 GMT
> [EMAIL PROTECTED] (Tom Daley) writes:
>> I have had bad service with Sony service as well. I bought a Sony
>> factory refurbished monitor. The image on the screen jitters from
>> side to side. I can't watch it for any length of time. I sent it
>> back for service (shipping at my expense). When it came back it
>> still had the problem.
I saw this on one machine at my previous university when
it was placed to near a certain wall. If you backed it away from the wall
a few feet it worked great. Don't know for sure what was in the wall (i'm
guessing maybe power lines leading to the roof air conditioner or
something, but i really don't know).
eric
------------------------------
From: Sean <[EMAIL PROTECTED]>
Subject: register_symtab()
Date: Thu, 27 Jul 2000 13:20:30 -0600
Where the register_symtab() goes to under Kernel 2.2?
Sean.
------------------------------
From: alex <[EMAIL PROTECTED]>
Subject: Re: A good IDE
Crossposted-To: comp.os.linux.development.apps,comp.os.linux.development
Date: Thu, 27 Jul 2000 12:17:34 -0700
Bruce Stephens <[EMAIL PROTECTED]> wrote:
> Most recently, Source Navigator was released under the GNU GPL.
> Source Navigator is the last bit of Code Fusion (Cygnus/RedHat's
> IDE thingy) to be made freely available, so all of Code Fusion (I
> think, anyway---are there any bits still not available?) is now out
> there, free for anybody to use and improve.
> Specifically, I'd recommend that anyone working with C/C++ ought to
> get Source Navigator and Insight. Insight's not perfect (it's a
> gdb made into a GUI), but it has some nice features, and matches
> Source Navigator nicely.
Could anybody tell me where to get/download these? I searched and
couldn't find them?
Alex
* Sent from RemarQ http://www.remarq.com The Internet's Discussion Network *
The fastest and easiest way to search and participate in Usenet - Free!
------------------------------
From: Wolfram Faul <[EMAIL PROTECTED]>
Subject: SIGSEGV during interruptible_sleep_on
Date: Thu, 27 Jul 2000 22:11:17 +0200
Hallo,
I am programming a character device for kernel 2.4.0-test1 and have the
following problem.
This is not the real function but enough to describe the problem.
If I open this device and want read from it with fread() the program
sleeps perhaps for two or three seconds an then gets a segmentation
fault in fread(). If I make
>cat /dev/mydevice
it's the same behaviour. cat terminates after two or three seconds with
a segmentation fault.
ssize_t dev_read(struct file *filp,char *buf, size_t count,loff_t *pos)
{
static int i=0,k;
printk("waitdev: I will sleep now ... szzzzhhh\n");
interruptible_sleep_on((void *)&readQ);
printk("waitdev: Good morning\n");
... __copy_to_user()
return k;
}
Now my questions:
Do I use the interruptible_sleep_on correct ???
Is it possible that someone else than me wakes up the task
(I call wake_up_interruptible((void *)&readQ) somewhere else)?
If you need more information please let me know.
Thank you
Wolfram
------------------------------
Reply-To: "Norm Dresner" <[EMAIL PROTECTED]>
From: "Norm Dresner" <[EMAIL PROTECTED]>
Subject: Re: Asynchronous I/O
Date: Thu, 27 Jul 2000 21:13:00 GMT
Exactly how do you do IPC from a module to a user task? (I thought that was
the gist of what I was asking, wasn't it? Or am I that confused?)
Norm
Rick Ellis <[EMAIL PROTECTED]> wrote in message
news:8lnf0h$5jt$[EMAIL PROTECTED]...
> In article <_7Hf5.9974$[EMAIL PROTECTED]>,
> Norm Dresner <[EMAIL PROTECTED]> wrote:
>
> >I have a need to create an asynchronous I/O device from a device that is
> >currently synchronous and only allows one process at a time to open it so
> >there's no need for complex queues. I've read Rubini's write-up on this
and
> >I was hoping that there is a simpler solution by which I can send a
single
> >process a single signal without having to go the fasync_queue route.
>
> Could you use IPC to a process that serializes the requests?
>
> --
> http://www.fnet.net/~ellis/photo/linux.html
------------------------------
Reply-To: "Norm Dresner" <[EMAIL PROTECTED]>
From: "Norm Dresner" <[EMAIL PROTECTED]>
Subject: Re: register_symtab()
Date: Thu, 27 Jul 2000 21:15:13 GMT
There's a new API. Start looking at
http://www.atnf.csiro.au/~rgooch/linux/docs/porting-to-2.2.html
and related documents
Norm
Sean <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]...
> Where the register_symtab() goes to under Kernel 2.2?
>
> Sean.
>
------------------------------
From: [EMAIL PROTECTED] (Linus Torvalds)
Subject: Re: SIGSEGV during interruptible_sleep_on
Date: 27 Jul 2000 14:57:02 -0700
In article <[EMAIL PROTECTED]>,
Wolfram Faul <[EMAIL PROTECTED]> wrote:
>
>ssize_t dev_read(struct file *filp,char *buf, size_t count,loff_t *pos)
>{
> static int i=0,k;
>
> printk("waitdev: I will sleep now ... szzzzhhh\n");
> interruptible_sleep_on((void *)&readQ);
> printk("waitdev: Good morning\n");
>
> ... __copy_to_user()
>
> return k;
>}
>
>Now my questions:
> Do I use the interruptible_sleep_on correct ???
Almost certainly not. The fact that you needed to cast it to (void *)
probably means that you got the type wrong, and that cast is there to
shut the compiler up about a bad type.
A wait-queue should be set up with something like
DECLARE_WAIT_QUEUE_HEAD(readQ);
and then it should not have any trouble when you pass in
interruptible_sleep_on(&readQ);
and wake it up using "wake_up(&readQ)".
Linus
------------------------------
From: [EMAIL PROTECTED]
Subject: Re: JNI peer classes
Date: Thu, 27 Jul 2000 22:17:19 GMT
Rob--
our product, Junc++ion, works best the other way 'round, but it would
still be useful in this mode. Check out http://www.codemesh.com for
more information. We're currently in beta on NT but actively porting to
other platforms. Contact me if you need more information.
Alex
In article <8ln512$[EMAIL PROTECTED]>,
"Rob Love" <[EMAIL PROTECTED]> wrote:
> Hello,
> I am writing a communications program. I have C++ code that is
platform
> independent and I am going to run it through a JNI. I understand how
to call
> native C++ methods from the Java code, but I want to go farther. I
want to
> set up Java classes that correspond to native C++ classes, so that I
can use
> them from Java as if they were Java classes. I have been trying to
research
> this topic and have some rough examples, but nothing really usefull.
Any
> suggestions on how to do this or on where to look? Thanks...
>
>
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
From: Yew Fai, Wong <[EMAIL PROTECTED]>
Subject: major difference between uCLinux 2.0 and 2.4?
Date: Thu, 27 Jul 2000 22:29:17 GMT
Hello everybody :
Does anybody know the major differences and implications to mobile
network applications between uClinux kernel 2.0.38 and the latest
version of 2.4?
Thanks!
Yew Fai
[EMAIL PROTECTED]
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
From: Jonathan Lundell <[EMAIL PROTECTED]>
Subject: Re: Setting Serial-Port Status lines
Date: Thu, 27 Jul 2000 16:20:57 -0700
In article <[EMAIL PROTECTED]>, Robert Resch
<[EMAIL PROTECTED]> wrote:
> I'm searching for a way to set the Status-Lines on the Linux
> Serial-Ports. for example DTR from Low to High or from High to Low to
> drive a LED which is showing me a status of the machine
Use the ioctls TIOCMBIS & TIOCMBIC to set and clear (respectively) modem
control & other bits. Use arg= TIOCM_DTR for DTR.
Keep in mind that the driver sets and clears DTR itself in some cases
(as in open() & close()), so you'll need to open the line, set or clear
DTR, and then *not* close it.
--
/Jonathan Lundell.
[EMAIL PROTECTED]
------------------------------
From: tye4 <[EMAIL PROTECTED]>
Subject: function size
Date: Thu, 27 Jul 2000 16:28:19 -0700
If I have a module like:
=============
/* test.c */
void foo(void)
{
printf("foo\n");
}
===========
and built test.o,
gcc -c test.c -o test.o
Is there a way to find how many bytes are used up by the function foo()
only?
thx,
tye4
------------------------------
From: [EMAIL PROTECTED] (phil hunt)
Subject: Re: test
Date: Thu, 27 Jul 2000 23:59:26 +0100
On 27 Jul 2000 13:30:29 -0400, Johan Kullstam <[EMAIL PROTECTED]> wrote:
>
>please ignore. i don't have alt.test and my nntp server has been
>giving grief.
Try comp.test instead. Or uk.test. Or many other *.test newsgroups.
--
***** Phil Hunt *****
The RIAA have banned Napster -- so boycott the music industry!
Don't buy any CDs during August (especially on Tuesday 1st August).
Spread the word: put this message in your sig, tell all your friends.
See website <http://boycott-riaa.com/>.
------------------------------
From: Tim Muir <[EMAIL PROTECTED]>
Crossposted-To: alt.os.linux
Subject: Tracing fork system calls.
Date: Fri, 28 Jul 2000 12:30:15 +1000
Hi
I am currently in the middle of the development of an alternative to sudo
which uses the tracing mechanisms built into the kernel (namely ptrace) to
intercept and examine system call arguments before a call is allowed to
proceed.
I was hoping not to have to alter the kernel source, but if I must, I
must. My problem begins when tracing a fork call.
My program will intercept both returns from the call and can continue to
trace the parent process (attached using the PTRACE_ATTACH argument to
ptrace). However, before I can attach the child process, it has continued
to run and I miss important system call executions. For example, I can
trace a bash shell. When the user types a command, bash will fork, and the
child process performs an exec on the required program.
But by the time I have attached the child process, the exec has already
been allowed to proceed.
I have tried various schemes like increasing the priority of the tracing
task and decreasing the priority of the traced tasks, but this is not
particularly reliable or secure.
On Solaris there is a INHERIT_ON_FORK flag which can be set using the
/proc fs. This means that the child process is automatically assigned to
be traced as it is created (if its parent was being traced).
I have looked into the Linux /proc fs and seen the stat field for a
process, however the documentation (man and khg included) does not
provide sufficient information for me to determine whether or not it is
useful.
Does anyone know how I can cause all children of an attached process to be
automatically attached ( I know this would break things like strace and
probably gdb) or better yet make sure that the child of a traced process
is stopped as soon as the task is created - so that I can attach it and
then tell it to continue running.
Timothy Muir
------------------------------
** FOR YOUR REFERENCE **
The service address, to which questions about the list itself and requests
to be added to or deleted from it should be directed, is:
Internet: [EMAIL PROTECTED]
You can send mail to the entire list (and comp.os.linux.development.system) via:
Internet: [EMAIL PROTECTED]
Linux may be obtained via one of these FTP sites:
ftp.funet.fi pub/Linux
tsx-11.mit.edu pub/linux
sunsite.unc.edu pub/Linux
End of Linux-Development-System Digest
******************************