Linux-Development-Sys Digest #308, Volume #8     Wed, 29 Nov 00 05:13:10 EST

Contents:
  Re: [Q] How to get the Ethernet address ? (scz)
  kernel and protected mode ([EMAIL PROTECTED])
  Re: hi, i need some help with a parallel port (Dan Mills)
  Re: Portable way of accessing PCI device from user space ("Ken Whaley")
  Direct Serial Connect Puzzler (John Kelly)
  Re: Direct Serial Connect Puzzler ("Daniel Prather")
  Re: CIFS.. (Volker Kuhlmann)
  WHAT "void value not ignored as it ought to be" means when I try to complie a file? 
(Terry Lee)
  fdisk sources (MESMEUR Philippe)
  Re: WHAT "void value not ignored as it ought to be" means when I try to  (Josef 
Moellers)
  System V Semphores and Linux ([EMAIL PROTECTED])
  Re: non-portable port (Kasper Dupont)
  Re: Interprocess Communication ... (Frank Broicher)
  Re: Question about the development of Linux (Kasper Dupont)
  Re: Callback function between driver modules ??? (Kasper Dupont)

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

From: scz <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
Subject: Re: [Q] How to get the Ethernet address ?
Date: Wed, 29 Nov 2000 00:34:03 GMT

"Pillonel C�dric, NWS-PD-71" wrote:
> 
> Why nobody answers my question ? If you can't answer why do post so many messages ?
> 
> Here is my question, with some precisions !!!
> 
> I have "one" Ethernet interface and I want to get the MAC adresse of that
> interface. Which system call should I use in C++ to obtain this information ?
> 
> Is it clear enough ? If you don't know how, please don't answer !
<snip>

So why couldn't you do that the first time?

I responded because your post (and the subsequent reply from Phil)
are examples of larger problems:

1)  Original post was sent to three very different newsgroups, only
    one of which was actually somewhat appropriate.

2)  Original post was a vague request for help coupled with an
    apparent expectation of immediate assistance.

3)  First reply was from an individual reading every possible
    interpretation (reasonable or not) into the original vague post.

First point I was trying to make:  if you need help, be sure to provide
a detailed query with enough background information for someone to have
a chance of being able to assist you.  

Second point I was trying to make:  your query did indeed sound very
simple, and there was no point in trying to extrapolate your question
to the nth degree instead of merely asking for clarification [since
your goal wasn't 100% clear].

Don't bother getting irritated at me - I don't care.  I'm just the
guy with a bit of free time who was trying to lend a hand and possibly
provide some subtle hints on etiquette;  who knows, such hints may
actually help you get answers to your questions in the future.  In any
case I shall waste no more time on this matter.

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

From: [EMAIL PROTECTED]
Subject: kernel and protected mode
Date: Wed, 29 Nov 2000 02:27:38 GMT



I'd like to get some information about the kernel structure :

- how many sections is there in the kernel ?
- are sections always at the same offsets in /dev/kmem each time linux
boot ?
- what is the minimal amount of memory to be allocated in one time ?
- What is the use for /boot/System.map, since /proc/ksyms provides
every exported symbols ?


If you have great documentations about protected mode on intel
architectures, i'd like to get it ([EMAIL PROTECTED]) .

=========
Julien VANEGUE


Sent via Deja.com http://www.deja.com/
Before you buy.

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

From: Dan Mills <[EMAIL PROTECTED]>
Subject: Re: hi, i need some help with a parallel port
Date: Wed, 29 Nov 2000 02:50:12 +0000

Glitch <[EMAIL PROTECTED]> wrote:

> I made that change last night and i dont get the compiler warning
> anymore and even teh segfault has disappeared however nothing appears on
> the LEDs of the custom board.

> My prof. said that the board is using 0x300 but i found out my sound
> card was using that address. He said I could goto Intel's site to get
> the info on the P8255A chip to set teh dip switches to use another
> address but i found no info on that chip on INtel's site.  I did however
> remove my sound card and used DOS's debug command to send bytes to
> address 300 and then read from that same port but the bytes I got back
> were always FF whether I sent 11 or aa to the port.  Windows recognizes
> that an unknown device is using address 300 but for some reason I'm not
> receiving the same bytes I'm sending to the port using DEBUG.

The problem is that the 8255 is a bidirectional io chip and all 3 of 
its ports default to inputs! You need to setup the status word to make 
your port driving the LEDs an output port, then it will work.
I do not have the data sheet for this part here, but it should not be 
hard to find.

There is nothing wrong with your code (once you got the order of the 
arguments to outb right, but you need to setup the 8255 first.

Regards, Dan.
-- 
The email address **IS** valid (You do **NOT** need to remove spamblock).
And on the evening of the first day the lord said.....
.... LX 1, GO!! and there was light!

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

From: "Ken Whaley" <[EMAIL PROTECTED]>
Subject: Re: Portable way of accessing PCI device from user space
Date: Tue, 28 Nov 2000 19:24:54 -0800


I'm assuming you're talking about a PCI device's memory
address range mapped by the memory base address register(s).
Portable to every known CPU in existence?   No.
Portable to modern mainstream desktop/server CPUs and
chipsets?  Yes.  E.g., x86, alpha, sparc.  At least, at the
read/write source code level.  You may need CPU-specific memory barrier
instructions, depending on the details of the mapping and of the device's
semantics. To get the absolutely best performance possible, you may need
additional CPU-specific code to map the device's address range(s)
using a fast memory mode (e.g., on Intel Pentium II,III,IV[I think],
you can set up your device to be mapped in USWC (Uncached Speculative
Write Combine) mode, allowing fast streaming writes, but with additional
ordering/flushing constraints.  Careful, this mode is tricky, be
sure you understand it and your device before attempting to use it.

So, your user code can be portable (with compile time decisisons
about where/when/if you need the memory barriers), but your
kernel-level initialization code will certainly differ between
different CPU/chipset combinations.

Going out on a limb, I think that simply mmap'ing /dev/mem
(using the PCI memory address range of your device) will generally
work on x86 and alpha linux on modern CPU+chipsets, but you
have to make sure you find the correct physical address (and of
course you need permission to write to /dev/mem, which is
usually reserved for root). In this way, you could get away with
no kernel code at all.   Not generally recommended, though.

    Ken

"Slawek Grajewski" <[EMAIL PROTECTED]> wrote in message
news:9015se$[EMAIL PROTECTED]...
> Hello,
>
> I've a question - how should I access PCI device from user space in a
> protable way? Is it possible at all? If yes, then how?
> As far as I know, on i386 architecture, it is just mmap and I can directly
> write to the PCI device memory. What about other architectures? Is it
> portable?
>
> Thanks,
> Slawek
>
>
>
>
>
>





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

From: John Kelly <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.networking
Subject: Direct Serial Connect Puzzler
Date: Tue, 28 Nov 2000 21:52:42 -0700

The Motivation:
===============

We have made some local modifications to the linux kernel to support a
product, but now, occasionally, everything will freeze up.  I'd like to
be able to jump into the running kernel with a debugger, and as I
understand it, this can only be done by attaching gdb from a second
machine connected over a serial port.

The Problem:
============

I'm just trying to test the serial port connectivity.  Machine A/ttyS0
and machine B/ttyS0 are connected through a null modem.  Here's what
I've tried:

A                              B                            Result
mgetty -r /dev/ttyS0           cu -l /dev/ttyS0             B: got
hangup signal
                                                            A: mgetty
blocks at select()

mgetty -r /dev/ttyS0           minicom                      B: nothing
                                                            A: mgetty
blocks at select()

minicom                        minicom                      B: nothing
                                                            A: nothing
                                                            Status bar
is "offline"
                                                            Zmodem
doesn't work

minicom                        Win2000 Hyperterminal        Characters
are echoed as garbage
                                (COM1)                      on each
other's screens.
                                                            Zmodem file
transfers work


Can anyone give me a pointer?

Thanks!
-jk



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

From: "Daniel Prather" <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.networking
Subject: Re: Direct Serial Connect Puzzler
Date: Tue, 28 Nov 2000 23:32:16 +0600

Well, the formatting in your message got a little funky on my end, but
... I have setup serial terminals and the like several times with Linux.
All you should have to do is setup mgetty on the serial port on one side,
and the other side uses a terminal program to use it.  I did this
primarily with Linux on one side, and an old laptop I had running an old
copy of MS Kermit on the other side.  Make sure your baud rates are set
to the same value on each side (start lower, around 9600, then work your
way up) ... Also, you say they're connected through a null modem ...
don't bash on me if I'm wrong here, but you mean null serial cable,
right?  Anyways, good luck!  Serial terminals are fun :)  At least, IMHO

Daniel Prather


In article <[EMAIL PROTECTED]>, "John Kelly" <[EMAIL PROTECTED]>
wrote:

> The Motivation:
> ---------------
> 
> We have made some local modifications to the linux kernel to support a
> product, but now, occasionally, everything will freeze up.  I'd like to
> be able to jump into the running kernel with a debugger, and as I
> understand it, this can only be done by attaching gdb from a second
> machine connected over a serial port.
> 
> The Problem:
> ------------
> 
> I'm just trying to test the serial port connectivity.  Machine A/ttyS0
> and machine B/ttyS0 are connected through a null modem.  Here's what
> I've tried:
> 
> A                              B                            Result
> mgetty -r /dev/ttyS0           cu -l /dev/ttyS0             B: got
> hangup signal
>                                                             A: mgetty
> blocks at select()
> 
> mgetty -r /dev/ttyS0           minicom                      B: nothing
>                                                             A: mgetty
> blocks at select()
> 
> minicom                        minicom                      B: nothing
>                                                             A: nothing
>                                                             Status bar
> is "offline"
>                                                             Zmodem
> doesn't work
> 
> minicom                        Win2000 Hyperterminal        Characters
> are echoed as garbage
>                                 (COM1)                      on each
> other's screens.
>                                                             Zmodem file
> transfers work
> 
> 
> Can anyone give me a pointer?
> 
> Thanks!
> -jk
> 
>

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

From: [EMAIL PROTECTED] (Volker Kuhlmann)
Subject: Re: CIFS..
Date: 29 Nov 2000 07:15:05 GMT
Reply-To: [EMAIL PROTECTED]

> Linux has smbfs (Samba) support and has for a long time. CIFS is MicroSoft's
> name for smb. I use the smbfs support in the kernel along with the Samba
> package to connect a Network Neighborhood of two Win98 machines via my Linux
> server.

The linux smbfs seems to work now, but the dates and times it displays
for files are completely shot (the linux fat fs is buggy too - where do
I report this to?). For a very nice product, try

http://www.obdev.at/Products/Sharity.html

Use the 2.4 beta, it's pretty stable. The automounter (and netowrk
neighbourhood) are pretty nifty. There are rpms as well.

Volker

--
Volker Kuhlmann  ([EMAIL PROTECTED])

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

From: Terry Lee <[EMAIL PROTECTED]>
Subject: WHAT "void value not ignored as it ought to be" means when I try to complie a 
file?
Date: Wed, 29 Nov 2000 07:54:20 GMT

WHAT "void value not ignored as it ought to be" means when I try to
complie a  file?
I use gcc.

Any comments will be appreciated.

--
==============================================
                          @
                   ~ ~~__=||_ ~ ~ ~~
               ~~ ~ ~  \____/ ~


Sent via Deja.com http://www.deja.com/
Before you buy.

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

From: MESMEUR Philippe <[EMAIL PROTECTED]>
Subject: fdisk sources
Date: Wed, 29 Nov 2000 09:04:29 +0100

hi,

I'm looking for fdisk's sources on the net but I can't find them.
can you please hellp me
-- 

========================================================
                Oce-Industries SA
                1, rue Jean Lemoine
                94015 Creteil cedex France                
                phone: 33-1-48988000  fax: 33-1-48985450
========================================================

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

From: Josef Moellers <[EMAIL PROTECTED]>
Subject: Re: WHAT "void value not ignored as it ought to be" means when I try to 
Date: Wed, 29 Nov 2000 09:14:07 +0100

Terry Lee wrote:
> =

> WHAT "void value not ignored as it ought to be" means when I try to
> complie a  file?
> I use gcc.
> =

> Any comments will be appreciated.

Any piece of source code that triggers this warning will be appreciated.

A wild guess:

void function();
=2E..
if (function())

But that's what it is ... a wild guess.
Oh how I long to have my glass sphere back!

-- =

Josef M=F6llers (Pinguinpfleger bei FSC)
        If failure had no penalty success would not be a prize (T.  Pratchett)

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

From: [EMAIL PROTECTED]
Subject: System V Semphores and Linux
Date: Wed, 29 Nov 2000 08:19:37 GMT

Hi,

over the last few months I developed an IPC-Library which encapsulates the
system calls needed to access semaphores, shared memory, pipes, and so on
(based on Steven's book). It is designed to support either System V or POSIX.
The basic problem is the support for Linux _and_ SGI's IRIX. IRIX is causing
no problems, but porting the Lib to Linux reveales some strange behaviour.
Basically porting the System V implementation to Linux should work, but on
some maschines it only seems to run. Getting a semphore using semget returns
a "normal" identifier and all operations on this semaphore cause no errors,
but when I look at the IPC state using ipcs then I'm told that there is no
semaphore allocated not to mention that all semaphore operations have no
effect. To top all this: on some maschines it works.

All works fine on my private maschine Suse Linux 7.0 (Kernel 2.2.16), it does
not work on a similar maschine at work and on maschines with Kernel 2.2.14
and (I know it's old) 2.0.36.

Does anybody know what is causing this strange incompatibilities?

THNX in advance

          Frank

Please reply also to: [EMAIL PROTECTED]



Sent via Deja.com http://www.deja.com/
Before you buy.

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

From: Kasper Dupont <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps
Subject: Re: non-portable port
Date: Wed, 29 Nov 2000 10:21:15 +0100

Frank Ranner wrote:
> 
[...]
> 
> Another alternative is the vcs and vcsa devices. These allow
> direct access to the tty memory similar to the dos access your
> program currently uses. See 'man vcs' for details. Of course this
> method is linux specific, non-portable, and requires the user to be
> root.
> 

It does not require the user to be root. On my RedHat6.0
system a user is given read/write acess to the appropriate
/dev/vcsXX and /dev/vcsaXX device at login. There might be
distributions where that does not happen.

Of course this is not portable, and it cannot be used
remotely or within X. Still in some cases it is the best
way to get some work done.

-- 
Kasper Dupont

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

From: Frank Broicher <[EMAIL PROTECTED]>
Subject: Re: Interprocess Communication ...
Date: Wed, 29 Nov 2000 09:28:28 GMT



>>>>>>>>>>>>>>>>>> Urspr=FCngliche Nachricht <<<<<<<<<<<<<<<<<<

Am 21.11.00, 21:14:55, schrieb [EMAIL PROTECTED] zum Thema Re:=20
Interprocess Communication ...:


> Hi,
>  Thanks for your replies.

>  They are not the same as SYSV calls. POSIX calls are different than
> SYSV calls. Also SYSV IPC's need some kernel parameter settings,which =
is
> not required on POSIX. RedHat Linux 6.2 is Kernel 2.2 or 2.4 ?

What kernel parameter settings?? I seem to have a problem with Sys V.

THNX=09
     Frank

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

From: Kasper Dupont <[EMAIL PROTECTED]>
Subject: Re: Question about the development of Linux
Date: Wed, 29 Nov 2000 10:59:05 +0100

Jason Lee wrote:
> 
> I am doing a software engineering research project about software
> development. The development of Linux especially interests me because
> its development is very different from other big software projects. I
> was able to find web sites about the history of Linux, but I couldn't
> find much information about how the process of development of Linux is
> organized. Does anybody know where I can find such information?
> 
> The following questions espectially interests me:
> 
> Is there a group of people who are mainly responsible to organize and
> manage the development of Linux?

A large group of persons, the files CREDITS and
MAINTAINERS distributed with the kernel contains
more information.

> 
> Who incorporate the new patches and new ported program into Linux (the
> whole package, instead of just the kernal, i mean)? Distributors like
> Redhat make the decision or their own distribution or is there some kind
> 
> of standard of what to put in?

Each distributor is allowed to make their own
choice, but they normally use the most recent
stable version, perhaps with a few additions.

> 
> Is their anybody or website who keep track of all the revisions of
> Linux?

<URL:http://www.kernel.org/>

> 
> Who actually release the Linux kernal? Who decide if the current version
> is a prerelease or an official release?

Linus Thorvalds himself I believe.

> 
> Regards,
> 
> Jason

-- 
Kasper Dupont

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

From: Kasper Dupont <[EMAIL PROTECTED]>
Subject: Re: Callback function between driver modules ???
Date: Wed, 29 Nov 2000 11:02:46 +0100

Sean Bose wrote:
> 
> Hi Friends
>   Can there be callback functions which one driver module can
> register with another.  How can we ensure that the function is
> never swapped out?
> 
> thanks
>   Sean

A lot of modules register functions in other modules.
Modules are loaded into kernel memory which is never
swapped out. Swapping is used for code and data
located in userspace.

-- 
Kasper Dupont

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


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