Linux-Development-Sys Digest #777, Volume #8 Thu, 7 Jun 01 17:13:16 EDT
Contents:
Re: how can I get a change to "official" linux? (Eric Taylor)
Re: source code of "hostid" command
Re: how can I get a change to "official" linux?
Re: Highspeed Parallel Interface ("David Hawkins")
nfs problem as module in 2.4.5? (bill davidsen)
Re: how can I get a change to "official" linux? (jurriaan kalkman)
Re: thundering herd problem: the REAL scoop ([EMAIL PROTECTED])
Re: Porting solaris software to Linux ("Norman Black")
Re: Porting solaris software to Linux (Markus Gyger)
Re: Highspeed Parallel Interface (=?iso-8859-1?Q?Andr=E9?= David)
Re: FIFO
Re: Linux-2.4.5 (Jerry Peters)
Help with vloopback ("Ivo Nikolov")
----------------------------------------------------------------------------
From: Eric Taylor <[EMAIL PROTECTED]>
Subject: Re: how can I get a change to "official" linux?
Date: Thu, 07 Jun 2001 17:31:00 GMT
Martin von Loewis wrote:
> Eric Taylor <[EMAIL PROTECTED]> writes:
>
> > So, is there in fact an "official" linux and how would I propose
> > such an enhancement?
>
> Others have already answered, but let me try also.
>
> Yes, there is an "official" Linux kernel; this is the one released by
> Linus Torvalds. John Reiser is right that it will take many years from
> the moment you propose a feature to the time the typical Redhat user
> gets it installed by default.
Suppose Linus liked my idea. Couldn't this get included into some 2.4.x
uppcoming release? My change is so slight and almost risk free (it does not
involve any logic), and wouldn't even come into play unless someone bothered
to write to a file like /proc/so_start_location. All the change does is
make
a kernel constant into a variable. The constant is only referenced in one
place.
I assume that these sorts of tuning /proc variables have some standard way
of sync-ing while the variable get's changed. I would probably need that
too.
>
>
> You can propose it here, or on the linux-kernel list. Unless you
> provide a *very* good rationale, and a patch, nothing will likely
> happen. Of course, if you provide funding for a kernel hacker, that
> might be another option.
>
> > It would allow for the (re)-positioning of the .so libraries so I
> > can have a nearly 3 gig (contiguous) array.
>
> If you want to reposition your shared libraries, I suggest that
> changing/improving ld-linux.so is a better way. Alternatively, setting
> the preferred load address in the shared libraries might be good enough.
Ok, my initial post essentially included the proposal. It is to make
a constant into a variable so I can dynamically decide where the
.so libraries load into virtual address space.
I believe the best solution to this, (which is way beyond my abilities) is
to allow for a link time option that states where to begin loading the
dynamic
libraries. However, short of that, I can get the same effect, (but for
_all_ programs on a system, instead of just one) by making one change
to ff/mmap.c and providing for a /proc variable.
======================
The constant I want to be variable is TASK_UNMAPPED_BASE.
I believe that this constant is used in only one place in ff/mmap.c
unsigned long get_unmapped_area(unsigned long addr, unsigned long len)
{
struct vm_area_struct * vmm;
if (len > TASK_SIZE)
return 0;
if (!addr)
addr = TASK_UNMAPPED_BASE;
....
===========================
Here is how it looks when I make my patch: The tradeoff is that I am
reducing the total size of the stack segment since I load the libraries
higher in virtual address space.
08048000-08578000 r-xp 00000000 08:05 3319497 /home/cbs/exe/cmr42.exe
08578000-08683000 rw-p 0052f000 08:05 3319497 /home/cbs/exe/cmr42.exe
08683000-12cac000 rwxp 00000000 00:00 0
a0000000-a0016000 r-xp 00000000 08:0b 28115 /lib/ld-2.1.92.so
a0016000-a0017000 rw-p 00015000 08:0b 28115 /lib/ld-2.1.92.so
a0017000-a0018000 rw-p 00000000 00:00 0
a0018000-a0019000 rw-p 00000000 00:00 0
a0019000-a001a000 rw-p 00000000 00:00 0
a0020000-a003f000 r-xp 00000000 08:0b 28128 /lib/libm-2.1.92.so
a003f000-a0040000 rw-p 0001e000 08:0b 28128 /lib/libm-2.1.92.so
a0040000-a015b000 r-xp 00000000 08:0b 28122 /lib/libc-2.1.92.so
a015b000-a0161000 rw-p 0011a000 08:0b 28122 /lib/libc-2.1.92.so
a0161000-a0165000 rw-p 00000000 00:00 0
a0165000-a01bd000 r-xp 00000000 08:05 2959719 /home/simjpl/lib/libsims.so
a01bd000-a01cc000 rw-p 00057000 08:05 2959719 /home/simjpl/lib/libsims.so
a01cc000-a1622000 r-xp 00000000 08:05 3319502
/home/cbs/exe/dll42.so_mod03
a1622000-a1840000 rw-p 01455000 08:05 3319502
/home/cbs/exe/dll42.so_mod03
We cannot live w/o the last .so, since that is ours and it must be a .so
so we can change code and then restart from a checkpoint.You mentioned
a way to set a preferred load address. I am not familiar with that, can you
point me to where that is discussed?
Also, can one change existing .so libraries to have a preferred address?
And is there a static library version of ld? Since as you can see above, ld
gets in the way too. My change moved _all_ .so files up in memory.
I have also written a small kernel memory patch program, that once I locate
the actual instruction that loads the value into a register, I can change
that
instruction (its a load immediate instruction so the constant is right
there). But
this requires me to disassemble the running kernel code. It will be at
different locations
and depending on the harware setting -386, pIII etc.- can change the
surrounding code so it is hard to automatically locate. However, once
I make the change it takes affect and I can change it as often as I like.
I don't do anything special, like disable interupts, when I patch the
location.
That is another downside to using this patch program.
I really think the rest of the user community would benefit from this
change.
If I was assured that I could get this into the official linux, I would
spend
the time and money to determine how to make this a /proc file. But
it is not worth it just for the experience, since I would be no better off
than if I were to just make the one line change and build my own kernel.
thanks
eric
>
>
> If you have a single application that needs contiguous memory, I
> suggest that link a static binary, and set the load address to some
> small value
>
>
> Regards,
> Martin
------------------------------
From: [EMAIL PROTECTED] ()
Subject: Re: source code of "hostid" command
Date: Thu, 07 Jun 2001 17:39:12 -0000
In article <9fms8i$31c6k$[EMAIL PROTECTED]>, Murphy <[EMAIL PROTECTED]> wrote:
>Is there someone who knows where I can get the source code of "hostid"
>command ? I'm interested in it. Thanks!
Use rpm to find out what package it is from and then grap the
source rpm:
rpm -qf `which hostid`
sh-utils-2.0-5
--
http://www.spinics.net/linux/
------------------------------
From: [EMAIL PROTECTED] ()
Subject: Re: how can I get a change to "official" linux?
Date: Thu, 07 Jun 2001 17:42:39 -0000
In article <[EMAIL PROTECTED]>,
Eric Taylor <[EMAIL PROTECTED]> wrote:
>Suppose Linus liked my idea. Couldn't this get included into some 2.4.x
>uppcoming release?
Here's what Linus says about submitting patches:
http://linuxtoday.com/news_story.php3?ltsn=2001-04-25-016-20-NW-KN
--
http://www.spinics.net/linux/
------------------------------
From: "David Hawkins" <[EMAIL PROTECTED]>
Subject: Re: Highspeed Parallel Interface
Date: Thu, 7 Jun 2001 11:03:15 -0700
Hi Brian,
Depending on how much fun you want to have :)
many FPGAs, and their associated development
boards can accept LVDS signals directly, i.e.,
you don't need to have a translator to shift the
levels. You could have a look around Xilinx's
web site, or Altera's web site and see what
development boards they have.
For Xilinx, look for a Virtex-FPGA board,
for Altera, look for an APEX board.
You'll find that they have PCI development
kits, and they should have a development
area, so you can build a connector to
your satellite receiver.
Alternatively, if you have a digital I/O card,
say from National Instruments, then you could
translate the data to LVTTL into one of the
digital I/O ports ... if the data rate is
too fast, then you could use an LVDS
serial-to-parallel converter. One would
assume that your 100Mbps is really a
serial stream of bytes or words, so the
actual data rate to the 'Linux kernel'
is going to be much slower. Is it continuous
data, or burst?
Anyway, since the satellite receiver will
have already imposed some data formatting
on the data stream, your best bet is to
undo the encoding in hardware - an FPGA
is great for this. Linux can then read
the buffered data, however, it wouldn't
be appropriate for performing the
serial-to-parallel conversion of the data.
Regards,
Dave Hawkins
Caltech.
"Bryan Christianson" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]...
> I have a board (Satellite receiver) that delivers output via a DB-25
> connector - 8 pins for data and a couple of clock/control pins at LVDS
> levels. Data rates could be as high as 100Mbps.
>
> What are my options for getting this data into kernel space where I can
> then do something useful with it. I assume I need a board that will
> plug into the PCI bus and has some kind of LVDS input interface.
>
> I've had a bit of a hunt around the net for LVDS/PCI boards but mostly
> they look too expensive for the budget of my project.
>
> Any help appreciated
>
> Regards
> Bryan Christianson
------------------------------
From: [EMAIL PROTECTED] (bill davidsen)
Subject: nfs problem as module in 2.4.5?
Date: Thu, 7 Jun 2001 18:34:22 +0000 (UTC)
I built a 2.4.5-ac5 kernel with NFS client as a module. When I tried to
load the module it gave me lots of warnings and failed. I am trying to
make a small kernel for possible floppy boot with only modules
absolutely needed for any given system (using initrd).
This works correctly built-in on the kernel. I no longer have a system
to try a bare 2.4.5 until the weekend, but I looked at the patches and
they don't seem to be anything which would cause this.
If someone can try this (or has) I'd like to hear. I'll try it over the
weekend on a machine which will be offline then.
--
bill davidsen <[EMAIL PROTECTED]> CTO, TMR Associates, Inc
"I am lost. I am out looking for myself. If I should come back before I
return, please ask me to wait." -seen in a doctor's office
------------------------------
From: [EMAIL PROTECTED] (jurriaan kalkman)
Subject: Re: how can I get a change to "official" linux?
Date: 7 Jun 2001 18:54:11 GMT
Reply-To: [EMAIL PROTECTED]
On Thu, 07 Jun 2001 17:31:00 GMT, Eric Taylor
<[EMAIL PROTECTED]> wrote:
>
>
> Martin von Loewis wrote:
>
>> Eric Taylor <[EMAIL PROTECTED]> writes:
>>
>> > So, is there in fact an "official" linux and how would I propose
>> > such an enhancement?
>>
>> Others have already answered, but let me try also.
>>
>> Yes, there is an "official" Linux kernel; this is the one released by
>> Linus Torvalds. John Reiser is right that it will take many years from
>> the moment you propose a feature to the time the typical Redhat user
>> gets it installed by default.
>
> Suppose Linus liked my idea. Couldn't this get included into some 2.4.x
> uppcoming release? My change is so slight and almost risk free (it does not
> involve any logic), and wouldn't even come into play unless someone bothered
If Linus likes it anything is possible, but you should try reading the
linux-kernel mailing list some time (few months) to see what Linus
mostly likes.
As far as I can comment on it, he doesn't like 'quick fixes' - if you
have a fundamental problem with a small patch that fixes the symptom he
may insist on fixing the fundamental problem. Read the lkml-archives
about device numbers - that should prove my point.
As for the technical part of your idea, I can't tell - I know nothing
about that.
Good luck,
Jurriaan
--
BOFH excuse #334:
50% of the manual is in .pdf readme files
GNU/Linux 2.4.5-ac9 SMP/ReiserFS 2x1402 bogomips load av: 0.41 0.11 0.03
------------------------------
From: [EMAIL PROTECTED]
Crossposted-To: comp.unix.programmer,comp.unix.bsd.freebsd.misc
Subject: Re: thundering herd problem: the REAL scoop
Date: 7 Jun 2001 18:08:38 GMT
In comp.unix.programmer Andrew Gierth <[EMAIL PROTECTED]> wrote:
| I think this is harder than it sounds. Since kqueues can't be shared
| between processes (at least in -STABLE), you have essentially the same
| problem in that you have N processes each with a kevent filter for the
| accept, and you have to direct the incoming connection to exactly one
| of them; the kernel has no way to choose which is the right one.
The multiple process select() racing to accept() is effectively a
random chance anyway. So while the kernel would have to choose some
process to wake up for a new connection, from among those waiting in
kevent(), the impact of an arbitrary choice wouldn't be any worse
than waking up the herd. If the choice ended up being FIFO, where
every process would take its turn, you might be waking up the most
swapped out process, but that would be a matter of the administrator
tuning the number of processes to match the machine. Of course one
could prefer a LIFO choosing mechanism. I don't think it should be
too hard to always pick from either the front or the back of the list.
| IMO descriptor-passing is a better solution, because it puts the
| control in the user process rather than relying on kernel guesswork.
Do you have any examples of programs that actuall use this? I was
thinking of doing things this way, too. I'm just worried about the
overhead involved.
| --
| Andrew.
| comp.unix.programmer FAQ: see <URL: http://www.erlenstar.demon.co.uk/unix/>
| or <URL: http://www.whitefang.com/unix/>
--
=================================================================
| Phil Howard - KA9WGN | Dallas | http://linuxhomepage.com/ |
| [EMAIL PROTECTED] | Texas, USA | http://phil.ipal.org/ |
=================================================================
------------------------------
From: "Norman Black" <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps,comp.unix.programmer,comp.unix.solaris
Subject: Re: Porting solaris software to Linux
Date: Thu, 7 Jun 2001 12:43:47 -0700
Reply-To: "Norman Black" <[EMAIL PROTECTED]>
> From information so far, I summarize:
> - There is thread/IPC issues
I have found the System V IPC APIs (semaphores, shared memory) to be the
same. I can't say I am a heavy user.
> - signal handling
For what little I do they are the same. I only use async signals to specific
threads. I do trap SIGSEGV and have found this the same using sigaction.
--
Norman Black
Stony Brook Software
the reply, fubar => ix.netcom
"jamal" <[EMAIL PROTECTED]> wrote in message
news:9fndaf$2mv$[EMAIL PROTECTED]...
> Thanks for the replies.
>
> FYI, the software is an online community service consists of several
modules
> such as
> chatting server, messenger servers, email service, BBS etc.
> So it is a large program. It use threads, semaphore, share memory etc.
> From information so far, I summarize:
> - There is thread/IPC issues
> - signal handling
> - compiler problem
>
> Another question:
> - Someone pointed me GNU autoconf and automake help to create more
portable
> code
> for *NIX application. How well these application help me to o the job as I
> know nothing about them.
>
>
> Regards,
>
> Jamal
>
>
> "jamal" <[EMAIL PROTECTED]> wrote in message
> news:9fhrtj$cho$[EMAIL PROTECTED]...
> > Hi ,
> >
> > I am new in linux or unix programming in general.
> > My company has an application written for Windows and Solaris.
> > We plan to port it to Linux. So the easiest should be porting
> > Solaris version into Linux version. I wonder what the main issues that I
> > should take care of for doing the porting.
> > Is it just compatibility between solaris system library and linux system
> > library or is there any specific
> > problem?
> > As I know that all unix system should have the similar API right? So in
> what
> > part they differ?
> > For your imformation the solaris software is compiled using sun cc
> compiler,
> > but there are some error when I tried to compile
> > using gcc, so obviously the compiler difference is one of the
> consideration.
> >
> >
> > regards
> >
> > Jamal
> >
> >
> >
> >
>
>
------------------------------
From: [EMAIL PROTECTED] (Markus Gyger)
Crossposted-To: comp.os.linux.development.apps,comp.unix.programmer,comp.unix.solaris
Subject: Re: Porting solaris software to Linux
Date: 7 Jun 2001 19:53:24 GMT
"jamal" <[EMAIL PROTECTED]> writes:
> For your imformation the solaris software is compiled using sun cc compiler,
> but there are some error when I tried to compile
> using gcc, so obviously the compiler difference is one of the consideration.
http://www.redhat.com/devnet/whitepapers/solaris_port/book1.html
does have some useful information about cc <-> gcc.
Markus
------------------------------
From: =?iso-8859-1?Q?Andr=E9?= David <[EMAIL PROTECTED]>
Subject: Re: Highspeed Parallel Interface
Date: Thu, 07 Jun 2001 21:47:57 +0200
This is a multi-part message in MIME format.
==============DD987F5C48A638951A9F2684
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Talking of FPGA's you can also design around a Lucent FPSC which has a
builtin ASIC PCI core. You just need to add a PCI carrier to it. That
is, if it is going to be a product... For devel the serial port looks
fine.
The ref is OR3LP26B.
HIH,
Andre
David Hawkins wrote:
>
> Hi Brian,
>
> Depending on how much fun you want to have :)
> many FPGAs, and their associated development
> boards can accept LVDS signals directly, i.e.,
> you don't need to have a translator to shift the
> levels. You could have a look around Xilinx's
> web site, or Altera's web site and see what
> development boards they have.
>
> For Xilinx, look for a Virtex-FPGA board,
> for Altera, look for an APEX board.
> You'll find that they have PCI development
> kits, and they should have a development
> area, so you can build a connector to
> your satellite receiver.
>
> Alternatively, if you have a digital I/O card,
> say from National Instruments, then you could
> translate the data to LVTTL into one of the
> digital I/O ports ... if the data rate is
> too fast, then you could use an LVDS
> serial-to-parallel converter. One would
> assume that your 100Mbps is really a
> serial stream of bytes or words, so the
> actual data rate to the 'Linux kernel'
> is going to be much slower. Is it continuous
> data, or burst?
>
> Anyway, since the satellite receiver will
> have already imposed some data formatting
> on the data stream, your best bet is to
> undo the encoding in hardware - an FPGA
> is great for this. Linux can then read
> the buffered data, however, it wouldn't
> be appropriate for performing the
> serial-to-parallel conversion of the data.
>
> Regards,
>
> Dave Hawkins
> Caltech.
>
> "Bryan Christianson" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]...
> > I have a board (Satellite receiver) that delivers output via a DB-25
> > connector - 8 pins for data and a couple of clock/control pins at LVDS
> > levels. Data rates could be as high as 100Mbps.
> >
> > What are my options for getting this data into kernel space where I can
> > then do something useful with it. I assume I need a board that will
> > plug into the PCI bus and has some kind of LVDS input interface.
> >
> > I've had a bit of a hunt around the net for LVDS/PCI boards but mostly
> > they look too expensive for the budget of my project.
> >
> > Any help appreciated
> >
> > Regards
> > Bryan Christianson
--
"Share the code. If you hide it ain't good."
Popular knowledge
==============DD987F5C48A638951A9F2684
Content-Type: text/x-vcard; charset=us-ascii;
name="Andre.David.vcf"
Content-Transfer-Encoding: 7bit
Content-Description: Card for Andr� David
Content-Disposition: attachment;
filename="Andre.David.vcf"
begin:vcard
n:David;Andr�
tel;cell:+41792013849
tel;work:+41227676147
x-mozilla-html:FALSE
org:CERN - European Centre for Nuclear Research;EP/NA60
adr:;;;;;;
version:2.1
email;internet:[EMAIL PROTECTED]
note:Geneva, Switzerland
x-mozilla-cpt:;-16000
fn:Andr� David
end:vcard
==============DD987F5C48A638951A9F2684==
------------------------------
From: [EMAIL PROTECTED] ()
Subject: Re: FIFO
Date: Thu, 07 Jun 2001 20:30:59 GMT
On Thu, 07 Jun 2001 16:02:17 +0200, Jan Pietrusky <[EMAIL PROTECTED]> wrote:
>Hello
>I will use a FIFO at my project. For at test, I wrote a small program to
>create and write in a fifo and another to read from that. It runs. The
>same code was written to my project, but the programm cannot open the
>fifo and hang it up. I analyzed the problem and found the following
>thing. The permission looks like different, the first one show
>
this isn't a fifo; it's a normal file
>4 -rw-r--r-- my_fifo //The test, that runs
>
>the other
>
>0 prw-r--r-- my_fifo| // that dont run
how does the ownership compare to the program opening it?
perhaps you should add write allow for group/others.
>Could anyone say me, what the problem is?
how about posting relevent snippets of your program?
>
>Thanks
>
>Jan
>--
> ---------------------------------------------------------------------
>| Dipl.-Ing.(FH) Jan Pietrusky | Tel: +49 (0) 3677 678331 |
>| Institut fuer Mikroelektronik- und | FAX: +49 (0) 3677 678338 |
>| Mechatronik-Systeme | |
>| Langewiesener Strasse 22, 98693 Ilmenau | |
>|---------------------------------------------------------------------|
>| MAIL/WWW: [EMAIL PROTECTED], http://www.imms.de/ |
> ---------------------------------------------------------------------
------------------------------
From: Jerry Peters <[EMAIL PROTECTED]>
Subject: Re: Linux-2.4.5
Date: Thu, 07 Jun 2001 21:01:10 GMT
D. Stimits <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
>>
>> I have been trying to upgrade from RH2.2.12-20 to kernel 2.4.5. I am
>> running an AMD-K6-2 processor with 64mb ram, a CreativeLabs PCI 512 sound
>> card, and a Lynksys NIC. The kernel freezes at boot. It only gets as for as
>> Uncompressing linux.... Ok boot. This not verbatum but close. I tried 2.4.3
>> previously with the same problem. The pathes were unsuccessful.
>>
>> B.M. Richard
>>
>> --
>> Posted via CNET Help.com
>> http://www.help.com/
> There are several bugs that might do this (I found one on my machine,
> despite the cockroach poison), which are corrected in Alan Cox's ac
> series of patches. Try patching with:
> ftp://zeus.kernel.org/pub/linux/kernel/people/alan/2.4/patch-2.4.5-ac9.bz2
> D. Stimits, [EMAIL PROTECTED]
What processor did you build it for? The default for 2.4.x is P3.
Jerry
------------------------------
From: "Ivo Nikolov" <[EMAIL PROTECTED]>
Crossposted-To:
alt.os.linux.mandrake,comp.os.linux.development,comp.os.linux.development.apps,comp.os.linux.misc
Subject: Help with vloopback
Date: Thu, 07 Jun 2001 21:09:11 GMT
Hi all,
I need to create an OVERLAY video source with vloopback so that RealProducer
can use it.
Anyone can give me some help?
Thanks,
Ivo
------------------------------
** 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 by posting to the
comp.os.linux.development.system newsgroup.
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
******************************