Linux-Development-Sys Digest #789, Volume #6      Sun, 6 Jun 99 08:15:18 EDT

Contents:
  Re: A simple question... (Igor Zlatkovic)
  Re: How to get all PID ? (George MacDonald)
  Re: How to determine tick frequency at runtime? (George MacDonald)
  Re: Reliable (!) nic for 2.2 kernel? (Peter Samuelson)
  Re: Developing device drivers for Linux... (Peter Samuelson)
  Re: TAO: the ultimate OS (David Fox)
  Re: HELP with interfacing PCs with Macs thorugh linux (Peter Samuelson)
  Re: drivers for a Graphics card (Peter Samuelson)
  Re: Rebuilding SRPMs (Johan Kullstam)
  great news - Ibm VisualAGe Java for Linux!! (Judah Diament)
  ltwinmodem (Rulecoyote)
  Re: YOURE NOT GOING TO BELIEVE THIS!  600 (Johan Kullstam)
  How do I compile ncurses? ("Chris Fanning")
  Re: NT driver writer new to Linux kernel/drivers (Peter Samuelson)
  Re: system call (Peter Samuelson)
  Re: Linux equivalent technologies to Win32? ("Dirk-Jan C. Binnema")
  Re: ltwinmodem (Peter Samuelson)
  Re: A simple question... (Peter T. Breuer)
  Re: ltwinmodem (Roope Anttinen)

----------------------------------------------------------------------------

From: Igor Zlatkovic <[EMAIL PROTECTED]>
Subject: Re: A simple question...
Date: Sat, 05 Jun 1999 23:43:41 +0000

> This extracted text is from the file you can find on the 2.3.5 kernel. As you
> can see, there are only a few motherboards on both lists, so I think a) many
> motherboards are giving any of these entries or b) people is using Linux SMP
> kernel but they are not reporting success stories to SMP developers.

Well, I always think that mails like "hey everything works here" bug those guys :-)
--
Igor


------------------------------

From: George MacDonald <[EMAIL PROTECTED]>
Subject: Re: How to get all PID ?
Date: Sun, 06 Jun 1999 00:23:21 GMT

Arun Sharma wrote:
> 
> "Soohyung Lee" <[EMAIL PROTECTED]> writes:
> 
> > How can I get all Process ID running at any instance.
> > Not by script (ps aux), But in the C program .
> > I really need your help.
> 
> Oops, I didn't read your post properly. One possible way of doing it
> is parsing /proc. This is what ps aux seems to do.
> 
>         -Arun

>From my code for treeps ( http://24.1.97.22/gmd/tps/treepsfm.html )


        static  int      first=1;
        static  DIR     *dirp;          /* Directory ptr, opened  once */
 
        struct  dirent  *direntp;
        int              pid;
        lnode           *plist, *p;
      
        char            *e;             /* End of number in file name */
        char            *fname;

        plist = process_list;
        if ( first )            /* Only open the directory once */
        {
                dirp = opendir("/proc");
                if ( dirp == NULL )
                {
                        perror("opendir");
                        return(NULL);
                }
                first = 0;
        }

        /* scan the /proc directory for a list of current processes */

        while ( (direntp = readdir( dirp )) != NULL )
        {
                fname = direntp->d_name;

                if (    ( fname[0] == '.' ) &&   /* Skip . */
                        ( fname[1] == NULL_CHAR ))
                {
                        continue;
                }

                if (    ( fname[0] == '.' ) &&   /* Skip .. */
                        ( fname[1] == '.' ) &&
                        ( fname[2] == NULL_CHAR ))
                {
                        continue;
                }

                /* If not a number, then skip it. Some systems have
                 * other directories/files in the /proc directory
                 */

                pid = strtol( fname, &e, 10 );
                if ( e == fname )
                {
                        continue;               /* not a number */
                }

                /* Ok fname is a process so add to list */

                ...
        }
        rewinddir( dirp );

        ...
}

-- 
We stand on the shoulders of those giants who coded before.
Build a good layer, stand strong, and prepare for the next wave.
Guide those who come after you, give them your shoulder, lend them your code.
Code well and live!   - [EMAIL PROTECTED] (7th Coding Battalion)

------------------------------

From: George MacDonald <[EMAIL PROTECTED]>
Subject: Re: How to determine tick frequency at runtime?
Date: Sun, 06 Jun 1999 00:26:15 GMT

Mark Frazer wrote:
> 
> Can I determine the value of tick as found in
> kernel/sched.c at runtime?
> 
> (Yes, I'm using third party drivers they're not
> willing to give out the source for.  Ug.)

try

 man sysconf

-- 
We stand on the shoulders of those giants who coded before.
Build a good layer, stand strong, and prepare for the next wave.
Guide those who come after you, give them your shoulder, lend them your code.
Code well and live!   - [EMAIL PROTECTED] (7th Coding Battalion)

------------------------------

From: [EMAIL PROTECTED] (Peter Samuelson)
Crossposted-To: comp.os.linux.networking
Subject: Re: Reliable (!) nic for 2.2 kernel?
Date: 5 Jun 1999 19:47:03 -0500
Reply-To: Peter Samuelson <[EMAIL PROTECTED]>

[bryan <[EMAIL PROTECTED]>]
> irix has an ifconfig switch to set speed and duplex.  why doesn't
> linux?  when I proposed this to some linux kernel and networking
> folks, I got totally ignored.  not sure why, really

Hmmm, how does the Linux developers' saying go?

> maybe I'll write it.

Oh yeah.  Now I remember.  "A line of code is worth a thousand words."

It is well to remember that.  I often forget it, unfortunately.  I am
always saying things like "now here is a feature that would be really
neat" ... "this is how I would do things" ... "they ought to write"
... and do not, myself, produce all that much original code.

> even if its not acceptable to some kernel folks, at least 2 people
> think this is the right place for it (ifconfig).. ;-)

<AOL>Three.</AOL>

-- 
Peter Samuelson
<sampo.creighton.edu!psamuels>

------------------------------

From: [EMAIL PROTECTED] (Peter Samuelson)
Subject: Re: Developing device drivers for Linux...
Date: 5 Jun 1999 20:12:44 -0500
Reply-To: Peter Samuelson <[EMAIL PROTECTED]>

[Chris White <[EMAIL PROTECTED]>]
> I need to develop a device driver for a pointing device which
> connects to the PS/2 port.  However, due to proprietary algorithms
> that I am unable to release in source code form, I need to be able to
> distribute my driver in binary form without having to rebuild the
> kernel to make it usable.

Hmmm.  Setting aside the licensing issues for a moment, realize that
you might not have to touch the kernel itself.  You will want to
investigate whether your driver can just be a userspace program that
opens /dev/psaux (the PS/2 port) or whether you will in fact need to
modify the kernel psaux driver itself.

Linux does not support pointing devices directly in the kernel the way
some OS's do.  This could change somewhat with KGI, but for the moment,
the kernel provides only the support to use the serial port, the PS/2
port, and various busmouse cards; the actual mouse driver part is done
with drivers in `gpm' (General Purpose Mouse) and `XFree86' (the X
Window System server), two normal userspace programs that access those
device files and provide console mouse services.

Back to the license issue: the generally agreed interpretation of the
GPL for Linux is that you may use the kernel module interface freely;
it is considered similar to using the system call interface (i.e. all
Linux programs do *not* have to be GPL-compliant).  If you need to
modify the kernel outside the module API, *those* modifications have to
be free.  Note that allowing modules to be non-free is actually a
concession Linus has made.

Therefore if you *do* have to modify the psaux driver, you can probably
only do it (non-free-ly) in Linux 2.0.x, since as of late in the 2.1
cycle it can no longer be compiled as a module.  (This is because psaux
has been merged with the standard keyboard driver.)

HTH.

-- 
Peter Samuelson
<sampo.creighton.edu!psamuels>

------------------------------

From: d s f o x @ c o g s c i . u c s d . e d u (David Fox)
Crossposted-To: alt.os.linux,comp.os.linux.advocacy,comp.os.misc,comp.unix.advocacy
Subject: Re: TAO: the ultimate OS
Date: 05 Jun 1999 18:37:52 -0700

[EMAIL PROTECTED] (Vladimir Z. Nuri) writes:

> in response to your tedious points that make absolutely
> no reference to the sssay whatsoever..
> 
> 1) the essay states ways to achieve goals very precisely.

I won't address all these points, but the following statements are
typical of your document.  As far as I can tell they are all simply
statements of vague though laudable goals with no hint as to how to
begin to achieve them:

  Viruses are impossible to contract on the system based on its
  design.

  Many common failures associated with existing OSes are impossible in
  Tao due to stability features.

  In Tao, the source of problems are always very easy to diagnose even
  by an end user.

  In Tao *everything* is *always* "plug-and-play". All hardware, all
  software, everything.  Anything can be connected or disconnected at
  any time with the system handling it elegantly in every situation.

I must side with your detractors, I can find no useful design insights
here.
-- 
David Fox           http://hci.ucsd.edu/dsf             xoF divaD
UCSD HCI Lab                                         baL ICH DSCU

------------------------------

From: [EMAIL PROTECTED] (Peter Samuelson)
Subject: Re: HELP with interfacing PCs with Macs thorugh linux
Date: 5 Jun 1999 20:39:28 -0500
Reply-To: Peter Samuelson <[EMAIL PROTECTED]>

[Bernd Strieder <[EMAIL PROTECTED]>]
> Try to find the SMB-protocol for your MACs. Does SAMBA run on MACs? I
> don't know MACs enough.

Of course it does.  You just have to load Linux on them first....

If you want to stick with Mac OS, Thursby Software makes Mac SMB client
software called Dave.  I don't know anything about it, though.

-- 
Peter Samuelson
<sampo.creighton.edu!psamuels>

------------------------------

From: [EMAIL PROTECTED] (Peter Samuelson)
Subject: Re: drivers for a Graphics card
Date: 5 Jun 1999 19:54:19 -0500
Reply-To: Peter Samuelson <[EMAIL PROTECTED]>

> > > I'm looking for a driver to download on Linux System for my
> > > Graphics card which is a 740 AGP Intel card.
[C Hanish Menon <[EMAIL PROTECTED]>]
> Also try www.xfree86.org if u are looking for X Window driver |
> server.  Most probably it will be supported by the XF86SVGA server.

Will be, but not yet.  See http://www.xfree86.org/releaseplans.html.
The i740 driver from Precision Insight is in 3.3.4, to be released
within a couple weeks.

-- 
Peter Samuelson
<sampo.creighton.edu!psamuels>

------------------------------

Crossposted-To: comp.os.linux.misc
Subject: Re: Rebuilding SRPMs
From: Johan Kullstam <[EMAIL PROTECTED]>
Date: 31 May 1999 09:10:12 -0400

David Wragg <[EMAIL PROTECTED]> writes:

> The PPro and successors have conditional move instructions. These can
> give quite significant performance improvements in typical code, by
> eliminating branch mispredictions. For a kernel built with egcs-1.1,
> there are measurable performance differences between one with
> -mpentiumpro and one with -march=pentiumpro (the latter enables egcs
> to use the cmov instructions). People get excited about the MMX and
> KNI instructions, but the use of the much more mundane cmov can give
> performance improvements for typical code, and it doesn't require
> compiler heroics.

agreed.  mmx is a largely worthless marketing ploy.

> Unfortunately, there have been bugs in the cmov support of all release
> versions of egcs so far. So you get a faster kernel that doesn't work
> reliably.

i agree that cmov has potential.  it's also rarely emitted by egcs.  i
am not sure how much real improvement there is.

-- 
                                           J o h a n  K u l l s t a m
                                           [[EMAIL PROTECTED]]
                                              Don't Fear the Penguin!

------------------------------

From: Judah Diament <[EMAIL PROTECTED]>
Subject: great news - Ibm VisualAGe Java for Linux!!
Date: Sat, 05 Jun 1999 22:23:37 -0400

see
http://www.software.ibm.com/ad/vajava/linux.html

------------------------------

From: [EMAIL PROTECTED] (Rulecoyote)
Subject: ltwinmodem
Date: 6 Jun 1999 01:40:49 GMT

Please tell me how to make a winmodem work with Linux!
 
                                                              oldcoyote

------------------------------

Crossposted-To: comp.os.linux.advocacy,comp.os.linux.x
Subject: Re: YOURE NOT GOING TO BELIEVE THIS!  600
From: Johan Kullstam <[EMAIL PROTECTED]>
Date: 31 May 1999 09:10:51 -0400

"CoughKool" <[EMAIL PROTECTED]> writes:

> where you born an idiot, or was it developed?
> <[EMAIL PROTECTED]> wrote in message
> news:7isrh3$6mfo$[EMAIL PROTECTED]...
> >
> > fcuwgxricgemxgethpuzo

it's a spammer trying out his software on a few dry runs.

-- 
                                           J o h a n  K u l l s t a m
                                           [[EMAIL PROTECTED]]
                                              Don't Fear the Penguin!

------------------------------

From: "Chris Fanning" <[EMAIL PROTECTED]>
Subject: How do I compile ncurses?
Date: Mon, 31 May 1999 14:34:22 +0200

Hi,

I'm new at this and have got a question.

How do I compile ncurses?

Sorry to bother.
Thanks.
Chris,



------------------------------

From: [EMAIL PROTECTED] (Peter Samuelson)
Subject: Re: NT driver writer new to Linux kernel/drivers
Date: 6 Jun 1999 01:29:58 -0500
Reply-To: Peter Samuelson <[EMAIL PROTECTED]>

[Holden McGroin <[EMAIL PROTECTED]>]
> BTW, are there threads in linux ?

Yes.  Reportedly, the model (pthreads, though there are a couple quirks
in the implementation) is in some ways not as sophisticated as the NT
threads model.  IANATP so I can't really discuss the issues
competently.

I guess the standard excuse for any threads shortcomings (and like I
said I'm not sure what those are) is that in Linux processes are so
lightweight that often threads don't buy you much anyway.

-- 
Peter Samuelson
<sampo.creighton.edu!psamuels>

------------------------------

From: [EMAIL PROTECTED] (Peter Samuelson)
Subject: Re: system call
Date: 6 Jun 1999 02:15:45 -0500
Reply-To: Peter Samuelson <[EMAIL PROTECTED]>

[NTVO910 <[EMAIL PROTECTED]>]
> Ok, I want my program to use the "su" or some similar command to
> change the account that the user is on.  I want it to try to change
> to the root account and type in the password for the user.

This is really a Unix question, not a Linux question.  If I understand
correctly, what you want is for your program (as a single process) to
somehow supply the right password to a function and get its privileges
modified to those of another user.

The Hurd allows for this functionality, but Unix (and Linux) does not.
In Unix, you can't gain privileges you didn't already have; you have to
*inherit* privileges from a process that *does* have them.  The only
way around this is to be executed as a setuid/setgid file; then the
kernel gives you the rights of the user/group the file is owned by.
(The other exception: a root process can renice you to a lower value.)

This is what `su' does: it runs setuid root, i.e. when it executes,
Unix gives it root privileges even though its parent process didn't
have them.  It checks the user's password against the passwd file, and
if all goes well, it spawns a shell and (optionally) runs a command
line as the correct user.  The *original process* did not gain any
privileges; these were only bestowed on the new process by the (setuid)
`su' process.  Comprende?

So *within* a program, you can't accomplish this.  The closest you can
come is to call execvp() on a setuid file, but then you lose your own
state.  You could hack `su' or something so that you could supply the
password in a non-interactive fashion (using, for example, `popen()')
which current versions of `su' do not let you do (at least without
allocating a pseudo-tty, which is probably overkill), then use that to
execute another process, somehow passing a baton of state information
as you do so.

Lots of people's wishlists for Linux (and other Unices) include a
feature of a setuid shared library, which would be a cleaner way to
handle this -- from a user perspective.  But I'm pretty sure the
resulting kernel implementation (`capable()' and friends) would be
*really* bloated, ugly and error-(read: security-hole-)prone.

-- 
Peter Samuelson
<sampo.creighton.edu!psamuels>

------------------------------

From: "Dirk-Jan C. Binnema" <[EMAIL PROTECTED]>
Subject: Re: Linux equivalent technologies to Win32?
Date: Sun, 6 Jun 1999 12:09:47 +0200

Hi there,

George Craig wrote in message ...

<snip>

>Listed below are additional technologies that I have worked with and would
>like to have compared to the equivalent *unix* incantation.


>1. COM / ActiveX    (is it CORBA?)


CORBA is used here, especially in the GNOME and KDE projects. They both also
have implementations of something like OLE2, "Bonobo" for GNOME, and
"KOM/OpenParts" for KDE.

>2. DCOM   (is it RPC, RMI in Java?)


You can use CORBA or RPCs or RMI.... whatever you like (I'd suggest CORBA).

>3. Transaction Monitoring of objects   (Enterprise JavaBeans - ETS?)


You could use EJB if your doing Java, or use CORBA with the Transaction
Service.

>4. Win32 API    (Any Window Manager flavor API and Libs? i.e., Gnome)


Win32 doesn't like 'separation of concern'. Unix does. So you get:

- GLibC for dealing with processes, threads, files, networking etc.
- Some UI library, e.g. GTK/GNOME or Qt/KDE or even 'straight Xlib' for X,
or ncurses for text mode


>Thanks for any and all of your help,
>George Craig
>
>[EMAIL PROTECTED]
>[if you want to respond, please remove NOSPAM]


Cheers,
    Dirk-Jan.



------------------------------

From: [EMAIL PROTECTED] (Peter Samuelson)
Subject: Re: ltwinmodem
Date: 6 Jun 1999 02:18:14 -0500
Reply-To: Peter Samuelson <[EMAIL PROTECTED]>

[Rulecoyote <[EMAIL PROTECTED]>]
> Please tell me how to make a winmodem work with Linux!

Write a driver.

-- 
Peter Samuelson
<sampo.creighton.edu!psamuels>

------------------------------

From: [EMAIL PROTECTED] (Peter T. Breuer)
Subject: Re: A simple question...
Date: 6 Jun 1999 07:40:14 GMT
Reply-To: [EMAIL PROTECTED]

Igor Zlatkovic ([EMAIL PROTECTED]) wrote:
: > can see, there are only a few motherboards on both lists, so I think a) many
: > motherboards are giving any of these entries or b) people is using Linux SMP
: > kernel but they are not reporting success stories to SMP developers.

: Well, I always think that mails like "hey everything works here" bug those guys :-)

No - I think the guy was just confused. The accept list is

   ALL - (blacklist - whitelist)

Not

   whitelist - blacklist

: --
: Igor


--
Peter

------------------------------

From: Roope Anttinen <[EMAIL PROTECTED]>
Subject: Re: ltwinmodem
Date: 6 Jun 1999 11:47:09 GMT
Reply-To: [EMAIL PROTECTED]

Rulecoyote <[EMAIL PROTECTED]> wrote:
> Please tell me how to make a winmodem work with Linux!

Persuade the manufacurer of that modem to port the driver to the Linux -
then you have ONE winmodem which can be used with Linux. What I'm saying is
that winmodems are "stupid" in a sense that they contain just some DSP and
all the work that is in traditional modems done in somewhat intelligent HW
is done with the driver the the PC's CPU.

This is an evil way of sawing few dimes from the manufacturing costs because
the modem is absolutely useless without driver for that particular HW
they are using in the thing and of course using that modem takes some of the
valuable CPU cycles.

IMHO people should wote against those pieces of crap with their wallets and
buy traditional modems. As you I'd return that.. that.. THING to the store
and demand some real modem instead.

Roope

-- 
MicroSoft? is that some kind of a toilet paper?
PS: Look for address here, not from headers. And remove NOSPAM's
___________________________________________________________________________
   [EMAIL PROTECTED]  /  [EMAIL PROTECTED]
        +358 9 812 7567  /  +358 500 445 565  /  +358 49 445 565
                http://myy.helia.fi/~anttiner/index.html
===========================================================================
   Helsinki Business Polytechnic - Institute of information technology

------------------------------


** 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
******************************

Reply via email to