Linux-Development-Sys Digest #202, Volume #8 Mon, 9 Oct 00 18:13:25 EDT
Contents:
Block Device Drivers ("[EMAIL PROTECTED]")
Re: adjtime and Linux 2.xxx (Nick Maclaren)
Re: Kernel Mailing lists at Red Hat? (Warren Young)
Re: What is Linux equivalent of Mac Toolbox? (Grant Edwards)
Driver Loading FPGA Device ([EMAIL PROTECTED])
Re: Text-based user interface development ([EMAIL PROTECTED])
Newbie question: ioremap (Mads Soerensen)
Re: Network Drivers help! (Kaz Kylheku)
A new directory hierarchy standard - need opinions (jtnews)
Re: A new directory hierarchy standard - need opinions (Alexander Viro)
Re: A new directory hierarchy standard - need opinions ([EMAIL PROTECTED])
Re: Most popular Linux development environment(s)? Graphical? (jazz)
Re: Kernel 2.4.0-test7, 8, and 9 "Warning pasting would not give a valid
preprocessing token" ? ("E-mu")
Re: A new directory hierarchy standard - need opinions (jtnews)
----------------------------------------------------------------------------
From: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
Subject: Block Device Drivers
Date: Mon, 09 Oct 2000 17:14:00 +0200
Hi,
In a linux block device driver,
The request_fn block function is protected by a spin lock and interupts
disabled (cli )
Can any one tell me where the critical sections are.
(I guess this is when something is copied to the buffer)
Thanks,
Richard Kolb.
------------------------------
From: [EMAIL PROTECTED] (Nick Maclaren)
Crossposted-To: linux.dev.kernel
Subject: Re: adjtime and Linux 2.xxx
Date: 9 Oct 2000 15:48:34 GMT
In article <[EMAIL PROTECTED]>,
Michel Bardiaux <[EMAIL PROTECTED]> writes:
|>
|> We have ported the BSD timeslave to Linux (Debian slink, kernel 2.0.36)
|> and adjtime definitely works *in that context*. But we have learned that
|> adjtime is one accursed API. On many OSes, it is either undocumented
|> (and Linux is one instance, where did you find the doc on your system?),
Documentation? What documentation? :-(
The trouble is that adjtime is the only decent interface for
setting the clock from a normal process. The problem with
settimeofday (a.k.a. clock_settime) is the risk of the process
being suspended between the calculation of the corrected time
and the execution of the change. This is BAD news.
While it is theoretically possible to make processes
non-interruptible on most Unices, the mechanisms for doing so
are extremely system-dependent, usually very complex, often
less well-documented than adjtime, fairly often need kernel
hacking and are extremely risky to use. If a process uses
them and then goes into a loop, your system is quite likely
to be dead.
msntp needs none of that hacking, and is extremely portable,
but it does need adjtime to avoid the interruptibility problem.
It will work without it, but ....
|> or does not work as the %&#$ doc says (e.g. SGI). On Linux, one crucial
|> line is in <kernel_src_dir>/kernel/sched.c, variable "tickadj". It reads
|>
|> int tickadj = (500/HZ ? : 1);
|>
|> in our sources (actually, we run timeslave on a tight leash, every 30
|> secs, because we need it, and we had to increase tickadj to 20 times
|> that). Do you have the same? What is your HZ? How did you discover the
|> clock is not updated?
Thanks. I will take a look at that. I don't offhand know what HZ
is set to. I certainly shouldn't need to poke at such things just
to set the clock.
msntp is an SNTP client etc., and its default mode is simply to
poll other NTP servers and print out the time, the difference and
an error estimate. It is thus a very good way of seeing what is
going on with the clock, without needing privilege, and many
people use it just for that. So all I did was to set up a reset
as root, and watch progress with the ordinary command.
|> Now, adjtimex, *that* one is tough! I haven't been able to understand
|> what it does, and its relation with the kernel PLL, or how the latter
|> works... so I'm still not able to use adjtimex.
I saw that once, and decided I didn't need it. I forget what it
looked like, except that it was truly horrible.
Regards,
Nick Maclaren,
University of Cambridge Computing Service,
New Museums Site, Pembroke Street, Cambridge CB2 3QG, England.
Email: [EMAIL PROTECTED]
Tel.: +44 1223 334761 Fax: +44 1223 334679
------------------------------
Date: Mon, 09 Oct 2000 11:48:32 -0600
From: Warren Young <[EMAIL PROTECTED]>
Subject: Re: Kernel Mailing lists at Red Hat?
moscito wrote:
>
> Hello, I would like to re-subscribe to the kernel mailing list and
> some other lists; I understand that they are now being hosted at Red
> Hat. Can someone inform me where linux-kernel and linux-smp went?
http://www.tux.org/lkml/
--
= Warren -- ICBM Address: 36.8274040 N, 108.0204086 W, alt. 1714m
------------------------------
From: [EMAIL PROTECTED] (Grant Edwards)
Crossposted-To: comp.os.linux.x,comp.os.linux.development.apps
Subject: Re: What is Linux equivalent of Mac Toolbox?
Date: Mon, 09 Oct 2000 18:07:21 GMT
In article <[EMAIL PROTECTED]>, Prasanth A. Kumar wrote:
>The two prominent highet level toolkits for Linux are 'GTK' and
>'QT'. Both are included with nearly all Linux distributions.
Tk is also used widely, but due to its design/implimentation,
it's generally used with interpreted languages (Python, Scheme,
Perl, Tcl). I suppose it's possible to use it with a compiled
language, but I've never seen an example.
The standard old-school Unix GUI toolkit used for many
commerical apps is Motif. It used to be available only
commercially, but a free version called lesstif is now fairly
mature. Motif/Lestif isn't used much in "new" OS projects, but
there are still a lot of legacy apps that use it.
There are other even older or more obscure toolkits, but we'll
ignore them for now...
--
Grant Edwards grante Yow! Why are these
at athletic shoe salesmen
visi.com following me??
------------------------------
From: [EMAIL PROTECTED]
Subject: Driver Loading FPGA Device
Date: Mon, 09 Oct 2000 18:03:20 GMT
One of the first tasks the driver I am writing must do is to read a .pof
file off of the system disk and program a FPGA device on the device
board. This is for a PCI device but I am not sure that is relevant to
this situation. Does anyone have or know of any code that implements
this?
Thank you.
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
From: [EMAIL PROTECTED]
Crossposted-To: comp.os.linux.development.apps
Subject: Re: Text-based user interface development
Date: Mon, 09 Oct 2000 18:31:37 -0000
In comp.os.linux.development.apps Larry Blanchard <[EMAIL PROTECTED]> wrote:
|> Lew Pitcher <[EMAIL PROTECTED]> wrote:
|> >Davide Dozza <[EMAIL PROTECTED]> wrote:
|> >
|> >>I am developing applications written in C/C++
|> >
|> >There is no such language as C/C++. There are two seperate,
...
| Yes, we have a living language that grows and changes. But some of us
| object when the growth gets cancerous :-). Lew's comment was proper.
Proper comment on a valid issue, but not in THIS thread.
I knew what Davide meant. Did you?
--
| Phil Howard - KA9WGN | My current websites: linuxhomepage.com, ham.org
| phil (at) ipal.net +----------------------------------------------------
| Dallas - Texas - USA | [EMAIL PROTECTED]
------------------------------
From: Mads Soerensen <[EMAIL PROTECTED]>
Subject: Newbie question: ioremap
Date: Mon, 09 Oct 2000 18:52:15 GMT
Hello
As a part of a project, we are trying to communicate with a PC-labcard
in our PC. It is a ISA card, and are mapped at 0xDB000 and 4kb more.
However, the problem is that we are not able to communicate with the
labcad.
As a total newbie, I have searched the net for examples and comed up
with a little piece of code that should print the value of the first
byte
#include <asm/io.h>
#define BASEADR 0xDB000
unsigned char * mapped;
int main(){
mapped = ioremap(BASEADR, 1024);
printf("Value: %x \n", *mapped);
}
But even this simple program dosn't work as we get the error:
undefined reference to ' __ioremap'
currently we compile using:
gcc -O2 -D__KERNEL__ -I/usr/src/kernel-source-2.2.16-storm/include -o
example example.c
As we cant compile the very basic example, we must obviously do
something very wrong. Please help!!!!!
Regards
Mads Sorensen
P.S: We know about the book Linux Device Drivers, but we won't be able
to get our hands on it for at least a week.
------------------------------
From: [EMAIL PROTECTED] (Kaz Kylheku)
Subject: Re: Network Drivers help!
Reply-To: [EMAIL PROTECTED]
Date: Mon, 09 Oct 2000 19:25:23 GMT
On Mon, 09 Oct 2000 11:33:53 +0300, Tasos Kotaras <[EMAIL PROTECTED]> wrote:
>Hello everybody
>
> Although I already have some experience in char device drivers, I
>feel lost as far as network drivers making is concerned.
>
> My current task is to create an HDLC driver for linux. (I'm going to
>use the on-chip capability of PPC860 for that). From what I have seen
>from the kernel sources, the socket abstraction that is used for the
>network
>drivers seems to add awful lot of complexity and overhead. Given that
>I'll be using it in an embedded set-up, this is an issue.
Drivers are not based on any socket abstraction. Sockets are an interface that
processes can use to talk to protocols or drivers; you can bind the right kind
of socket to a driver to do packet level I/O. But the socket object exists
independently of the driver, and the driver doesn't have to do anything special
to make that work.
> I would like to know if there is any way to avoid doing all this
>fuss with the sockets.
To write a network driver, you never have to touch sockets or even know what
they are or that they exist. You just have to implement the network device
driver interface, the core of which has to do with header construction and
passing packets (struct sk_buff objects) up and down.
>An idea that crossed my mind was that I may use a
>character device driver to do the job. I know that this will be a char
>rather than
>packet oriented solution, but with some additional effort it will be OK.
If you have a datalink device that resembles a serial line, it may make sense
to write a tty driver for it. Then your higher level datalink protocol like
HDLC can be implemented as a tty line discipline which is independent of the
driver. The line discipline can hook into the networking subsystem to appear as
a network device.
--
Any hyperlinks appearing in this article were inserted by the unscrupulous
operators of a Usenet-to-web gateway, without obtaining the proper permission
of the author, who does not endorse any of the linked-to products or services.
------------------------------
From: jtnews <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.admin,comp.os.linux.networking,comp.os.linux.setup
Subject: A new directory hierarchy standard - need opinions
Date: Mon, 09 Oct 2000 19:53:24 GMT
I propose a new naming scheme for the /usr directory, it should be
/usr/domain/com/company/subnet/applicationName/architecture/i386, then
you just make a simple script /usr/bin which links to every executable
in the /usr/domain directory.
An advantage of this scheme is that you can easily create maps for
automount to automatically mount the application remotely via NFS.
Looking forward, when broadband becomes widely available and bandwidth
becomes very cheap, there won't be any need to create distributions.
In addition, it might be possible to implement Sun's cachefs in Linux
so that the applications are automatically cached to a local hard disk
so you wouldn't have to use NFS all the time either.
Another advantage of this scheme is that since /usr/domain lies outside
of the current Linux FHS, it can be gradually phased in and need not
disrupt the current Linux environment.
I'd appreciate a lot of input on my proposal.
------------------------------
From: [EMAIL PROTECTED] (Alexander Viro)
Crossposted-To: comp.os.linux.admin,comp.os.linux.networking,comp.os.linux.setup
Subject: Re: A new directory hierarchy standard - need opinions
Date: 9 Oct 2000 16:58:57 -0400
In article <[EMAIL PROTECTED]>,
jtnews <[EMAIL PROTECTED]> wrote:
>I'd appreciate a lot of input on my proposal.
NFS stands for No Filesystem Security. Read on security issues with NFS
and if after that you will still think that your proposal makes sense -
seek professional help. NFS over untrusted network is a disaster waiting
to happen and it's not going to wait long, especially if you use it for
executables.
--
"You're one of those condescending Unix computer users!"
"Here's a nickel, kid. Get yourself a better computer" - Dilbert.
------------------------------
From: [EMAIL PROTECTED]
Crossposted-To: comp.os.linux.admin,comp.os.linux.networking,comp.os.linux.setup
Subject: Re: A new directory hierarchy standard - need opinions
Date: Mon, 09 Oct 2000 21:07:25 -0000
In comp.os.linux.development.system jtnews <[EMAIL PROTECTED]> wrote:
| I propose a new naming scheme for the /usr directory, it should be
| /usr/domain/com/company/subnet/applicationName/architecture/i386, then
| you just make a simple script /usr/bin which links to every executable
| in the /usr/domain directory.
Do you mean the literal string "architecture" as a directory name and
the a name for an architecture? I prefer well thought out positional
information where the situation is not so complex to need mnemonic.
And I don't believe this is anywhere near that complex. But what about
a version number so you can store more than one version?
How about:
/usr/domain/{tld}/{sld}[/{optional3ld...}]/{appname}/{arch}/{version}
where "current" can be used in the version to symlink to a version.
| An advantage of this scheme is that you can easily create maps for
| automount to automatically mount the application remotely via NFS.
| Looking forward, when broadband becomes widely available and bandwidth
| becomes very cheap, there won't be any need to create distributions.
| In addition, it might be possible to implement Sun's cachefs in Linux
| so that the applications are automatically cached to a local hard disk
| so you wouldn't have to use NFS all the time either.
|
| Another advantage of this scheme is that since /usr/domain lies outside
| of the current Linux FHS, it can be gradually phased in and need not
| disrupt the current Linux environment.
|
| I'd appreciate a lot of input on my proposal.
--
| Phil Howard - KA9WGN | My current websites: linuxhomepage.com, ham.org
| phil (at) ipal.net +----------------------------------------------------
| Dallas - Texas - USA | [EMAIL PROTECTED]
------------------------------
From: [EMAIL PROTECTED] (jazz)
Crossposted-To: comp.os.linux.development.apps
Subject: Re: Most popular Linux development environment(s)? Graphical?
Date: Mon, 09 Oct 2000 17:16:00 -0400
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] wrote:
> In our last episode (Sun, 08 Oct 2000 19:27:39 -0400),
> the artist formerly known as jazz said:
> >I'm thinking of switching from mac to Linux. If I did, what programming
> >setup would I likely find myself using? Gnu? Is there anything with
> >a graphical interface, esp. for the debugger, as in Codewarrior,
> >where you see a window containg your code and you can clearly mark
> >breakpoints and follow the program counter steping through your code?
> >With windows for variables, stack tracing, etc.?
>
> You won't find one single tool for this...
>
> There are several debuggers based on GDB; look for DDD, Insight FE, Code
> Medic, kdbg, HP Wildebeast.
>
> There are also a number of "IDEs" somewhat in the style of that
> introduced by Borland, including XWPE, RHIDE, Source Navigator,
> WipeOut, Code Crusader, KDevelop.
>
> Vis-a-vis editing/compiling software, it is common for programmers
> to wish not to be dependent on the availability or lack thereof of
> a particular "IDE"; it is common for programmers to be capable of
> coping with the lack of any graphical environment whatsoever. This
> is quite critical if you're trying to work with the kernel; there
> may well not be enough of the system functioning to allow you to
> have a GUI at all, and debugging in the kernel is Rather Special...
>
> It is not uncommon to use GNU Emacs as an "IDE on Steroids;" combining
> it with "etags" provides consider power in editing code...
I'm trying to understand your point. I CAN develop code using a command
line interface, with gcc, emacs as an editor, and the command line
debugger. But I find it primitive. I don't develop code for distribution;
I develop code to do a particular job (usually experiment control or data
analysis) in our lab, on a particular platform. I much prefer having a
graphical user interface like Codewarrior with a graphical debugger that
lets me see numerous lines of code in numerous functions in many windows
at once, with a window for multiple variables, execution tracing, analysis
tools to determine efficiency, a very good framework, etc etc etc.
Why would I NOT want this?
Thanks,
Jazz = not an expert
------------------------------
From: "E-mu" <[EMAIL PROTECTED]>
Subject: Re: Kernel 2.4.0-test7, 8, and 9 "Warning pasting would not give a valid
preprocessing token" ?
Date: 09 Oct 2000 21:26:50 GMT
What config file or file do I make these changes in ?
Thanks
"C. W. Wright" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]...
> > "Warning pasting would not give a valid preprocessing token". Each time
I
> > see the message it is proceeded by the following,
> > I am ccurrently running Red Hat 7.0
>
> I just did a "so-called" "upgrade" from RH 6.2 to RH 7.0 and I found that
even
> the Redhad provided SRPM for the installed kernel (2.2.16-22) would not
compile
> without errors. I grabbed a fresh 2.2.17 from www.kernel.org and I has
the
> same "pasting" problem as well as other problems.
>
> The fix I found that permitted flawless compilation of the 2.2.17 kernel
and
> modules was to change the gcc to kgcc as follows:
>
> HOSTCC = kgcc
>
> and
> CC = $(CROSS_COMPILE)kgcc -D__KERNEL__ -I$(HPATH)
>
>
> The kgcc was already installed on the 7.0 system.
>
> Although I have been able to compile two different kernels and a
realtime-linux
> patched kernel, I havn't been able to compile much of anything else and
have it
> work.
>
> W. Wright
>
>
>
> "THINGS ARE MORE LIKE THEY ARE NOW THAN THEY EVER WERE BEFORE."
> - Former U.S. President Dwight D. Eisenhower
>
>
>
>
>
------------------------------
From: jtnews <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.admin,comp.os.linux.networking,comp.os.linux.setup
Subject: Re: A new directory hierarchy standard - need opinions
Date: Mon, 09 Oct 2000 21:48:49 GMT
Alexander Viro wrote:
>
> In article <[EMAIL PROTECTED]>,
> jtnews <[EMAIL PROTECTED]> wrote:
>
> >I'd appreciate a lot of input on my proposal.
>
> NFS stands for No Filesystem Security. Read on security issues with NFS
> and if after that you will still think that your proposal makes sense -
> seek professional help. NFS over untrusted network is a disaster waiting
> to happen and it's not going to wait long, especially if you use it for
> executables.
Can you give a specific example of a security problem using this setup?
Note that it is the client that mounts a read only filesystem from the
server
which is presumably on the application service provider's side and is
secured
on that end.
------------------------------
** 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
******************************