Linux-Development-Sys Digest #680, Volume #7     Tue, 14 Mar 00 12:13:20 EST

Contents:
  Re: underscores ???? (Patrick E. Hughes)
  troubles with IDE drive > 32gig ([EMAIL PROTECTED])
  Re: module_list unresolved ?? ("Bernard Beauchamp")
  High resolution timer ("Bernard Beauchamp")
  Re: Bug found in localeconv! (Andreas Jaeger)
  Re: Trouble building KDE applications (David T. Blake)
  Re: High resolution timer (Maciej Golebiewski)
  Buffercache ("Erwin Ambrosch")
  Re: Kernel Module Problem (orion22) ("Peter T. Breuer")
  Re: Buffercache (Alan Donovan)
  Linuxconf html layout/linking modifications ([EMAIL PROTECTED])
  Re: 2.3.48 and spam?? (Mike Dowling)
  Re: [ERROR] modprobe: can't locate module parport_lowlevel (Bob Tennent)
  Re: Problems with NM256 module Kernel 2.2.14 (Dr H. T. Leung)
  INLINE methods inside (static) libraries !!! ("Luca Garulli")
  Re: Problems with NM256 module Kernel 2.2.14 (Thomas Gaertner)
  Re: underscores ???? (Alan Donovan)
  Help: Mapping complex data structs into shared memory. (Lewis Brown)
  linux in notebook ("Bass¨Ð¦õªv")
  Re: linux in notebook (Mike Dowling)
  Re: Help: Mapping complex data structs into shared memory. (Fabrice Peix)

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

From: Patrick E. Hughes <[EMAIL PROTECTED]>
Subject: Re: underscores ????
Date: Tue, 14 Mar 2000 08:15:43 GMT

>can someone clear these doubts wrt the to linux source code->
>1.  why are there so many functions beginning with underscores?  ie is
>there a reason for such naming?

Keeps the namespace from getting polluted.  The convention (C
programming in general) seems to be that functions meant to be used
only inside a library section get the underscore _fn().




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

From: [EMAIL PROTECTED]
Subject: troubles with IDE drive > 32gig
Date: Tue, 14 Mar 2000 08:11:35 GMT

I have this 36gig drive (Maxtor, 255sec * 63head * 4441cyl) partitioned
as one single large partition, formatted as ext2.  It seems when it reaches
about 32gig fill (in the powers of 2 sense, about 34gig in decimal form),
it begins to get corrupt.  I've had to reformat twice now.  This time even
the MBR was overwritten.  Linux kernel is 2.2.14.  Surely 2.2 is capable of
drives, partitions, and filesystems over 32gig, is it not?

My 30gig and 27gig drives have not encountered any such problems.

-- 
| Phil Howard - KA9WGN | for headlines that | Just say no to absurd patents |
| [EMAIL PROTECTED] | really matter:     | Boycott Amazon.Com (AMZN)     |
| Dallas - Texas - USA | linuxhomepage.com  | Shop http://bn.com/ instead   |

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

From: "Bernard Beauchamp" <[EMAIL PROTECTED]>
Subject: Re: module_list unresolved ??
Date: Tue, 14 Mar 2000 08:34:53 GMT

"module_list" is unfortunately not exported, nor is "kernel_module"

Bernard Beauchamp
www.systar.com

nilesh patel <[EMAIL PROTECTED]> a écrit dans le message :
[EMAIL PROTECTED]
> Hi
>     the code below compiles but the symbol module_list is unresolved.
>     Is the symbol module_list exported by the kernel or not ??
>
> If not what is the problem
>
>
>
>
> /* The necessary header files */
>
> /* Standard in kernel modules */
> #include <linux/kernel.h>   /* We're doing kernel work */
> #include <linux/module.h>   /* Specifically, a module */
>
>
>
> /* Deal with CONFIG_MODVERSIONS */
> #if CONFIG_MODVERSIONS==1
> #define MODVERSIONS
> #include <linux/modversions.h>
> #endif
>
>
> extern struct module *module_list;
> /* Initialize the module */
> int init_module()
> {
>         struct module *m = module_list;
>   printk("Hello, world - this is the kernel speaking\n");
>
>   return 0;
> }
>
>
> /* Cleanup - undid whatever init_module did */
> void cleanup_module()
> {
>   printk("Short is the life of a kernel module\n");
> }
>



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

From: "Bernard Beauchamp" <[EMAIL PROTECTED]>
Subject: High resolution timer
Date: Tue, 14 Mar 2000 08:42:07 GMT

Is there a way for a kernel module to get the current time with a better
resolution than jiffies (1/100 sec on I86)?

Thank You

Bernard Beauchamp
[EMAIL PROTECTED]




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

From: Andreas Jaeger <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development,linux.dev.kernel
Subject: Re: Bug found in localeconv!
Date: 14 Mar 2000 09:42:03 +0100

>>>>> Andre Charbonneau writes:

 > Hi
 > I found a bug in localeconv and isolated the part of the code which
 > contains the bug.  Here it is:

 >   result.p_cs_precedes = *(char *) _NL_CURRENT (LC_MONETARY,
 > P_CS_PRECEDES);
 >   result.p_sep_by_space = *(char *) _NL_CURRENT (LC_MONETARY,
 > P_SEP_BY_SPACE);
 >   result.n_cs_precedes = *(char *) _NL_CURRENT (LC_MONETARY,
 > P_CS_PRECEDES);

 > The above 3 lines are from localeconv.c.  Notice that the bug is in the
 > 3rd line (above)... it should use N_CS_PRECEDES instead of
 > P_CS_PRECEDES.

 > (To get around the bug, ln_langinfo can be used...)

 > I'm not sure if this is the proper place to post the bug.  If not, I
 > would appreciate if someone tell me where I should post the bug report.
localeconv is part of glibc and the best way to report bugs in glibc
is to use the glibcbug script.

I've forwarded your report this time myself.

Thanks,
Andreas
-- 
 Andreas Jaeger
  SuSE Labs [EMAIL PROTECTED]
   private [EMAIL PROTECTED]

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

From: [EMAIL PROTECTED] (David T. Blake)
Crossposted-To: comp.os.linux.setup,comp.os.linux.admin
Subject: Re: Trouble building KDE applications
Date: 14 Mar 2000 06:24:56 GMT
Reply-To: [EMAIL PROTECTED]

[EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Greetings,
> 
> I'm having trouble building KDE applications on my RedHat 6.1 system.
> 
> When running the configure script I get the following error:
> 
> checking for kde libraries installed... configure: error: your system
> fails at linking a small KDE application!

I am assuming
1) Before you did this you read the README and set the environment
variable QTDIR to point at the base of the QT installation. 
2) You edited /etc/ld.so.conf to include the qt/lib and kde/lib
directories, and reran ldconfig (as root) or, you set the environment
variable LD_LIBRARY_PATH to point at these two directories.


-- 
Dave Blake
[EMAIL PROTECTED]

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

From: Maciej Golebiewski <[EMAIL PROTECTED]>
Subject: Re: High resolution timer
Date: Tue, 14 Mar 2000 10:56:59 +0100

Bernard Beauchamp wrote:
> 
> Is there a way for a kernel module to get the current time with a better
> resolution than jiffies (1/100 sec on I86)?
> 
> Thank You
> 
> Bernard Beauchamp
> [EMAIL PROTECTED]

On Intel CPUs with Time Stamp Counter the function do_gettimeofday()
will get
you time with microsecond precision. But I don't know if this function
is
exported so that it could be used in a module.

Hope this helps,

Maciej

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

From: "Erwin Ambrosch" <[EMAIL PROTECTED]>
Subject: Buffercache
Date: Tue, 14 Mar 2000 12:21:42 +0100

Hi,

I'm using template files to generate *.html files.
As I know, Linux uses parts of the main memory
as cache.
Means that, that it is not necessary to write a simple
cache system which would keep the template files in
memory as long as they not modified on disk.

Erwin




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

From: "Peter T. Breuer" <[EMAIL PROTECTED]>
Subject: Re: Kernel Module Problem (orion22)
Date: 10 Mar 2000 23:54:50 GMT

Francisco Obispo <[EMAIL PROTECTED]> wrote:
: I'm using

: gcc -D__KERNEL__ -DLINUX -DMODULE -DMODVERSIONS -Wall

: to compile the module.... do I need anything else??

Yes. This is a FAQ,

   -O2

Now why couldn't you work that out from typing "make modules" in
the kernel source tree root?

Peter

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

From: Alan Donovan <[EMAIL PROTECTED]>
Subject: Re: Buffercache
Date: Tue, 14 Mar 2000 11:54:36 +0000

Erwin Ambrosch wrote:

> I'm using template files to generate *.html files.
> As I know, Linux uses parts of the main memory
> as cache.

Yes, the buffer cache holds some recently-used disk pages on the
assumption that pages recently accessed are more likely to be accessed
again soon.

> [Does this mean that (?)] it is not necessary to write a
> simple cache system which would keep the template files in
> memory as long as they not modified on disk.

If you are concerned that an HTTP server has to read a file from the
disk very frequently (e.g. several times per second) then the buffer
cache means that the physical disk will not be involved after the first
time.

However for very high performance, the context switch to kernel mode
while reading from the buffer cache may be undesirable; in that case you
should buffer these files in your application. However the only guide
here is hard data: start simple, and use a profiler if you need more
speed.

alan

-- 
========================================================================
  Alan Donovan     [EMAIL PROTECTED]    http://www.imerge.co.uk
  Imerge Ltd.      +44 1223 875265

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

From: [EMAIL PROTECTED]
Subject: Linuxconf html layout/linking modifications
Date: Tue, 14 Mar 2000 11:51:46 GMT

Hi all,

looking for info on how 2 modify the linux source
for configuring the html interface to linuxconf.

Say for example the nextwork if section, rather than
having the area presented in drop down boxes in very
plain html, I'd like to link each area to a nice
graphical link page.

Other info required:
is there _completely_ minimal firewall ipchains
firewall source out there using linuxconf?

Any info appreciated, the pride of up to 20 486s
depends on you!

Later,
Bill


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

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

From: [EMAIL PROTECTED] (Mike Dowling)
Subject: Re: 2.3.48 and spam??
Date: 14 Mar 2000 12:16:18 GMT

On 10 Mar 2000 05:04:58 -0600, Peter Samuelson 
<[EMAIL PROTECTED]> wrote:
>[Mike Dowling <[EMAIL PROTECTED]>]
>> I had sendmail-8.10.0.Beta12 running since 28th Feb.  In that time, I
>> had blocked spam via ORBS, DUL, and RBL, so it was working.
>> Suddenly, I received zillions of spams that were already listed in
>> ORBS and RSS.
>> 
>> Although it seems to me far fetched, the only change to my system
>> since then was to replace the 2.2.14 kernel with 2.3.48.  I have
>> since updated to 2.3.50, but could perhaps the networking code for
>> the 2.3.48 kernel have been somehow implicated?
>
>Strange as it may seem, yes, it could have been.  There was an issue
>with changing some semantics of UDP networking, and since DNS uses UDP,
>this could easily have affected your DNS timeouts, and of course RBLs
>are based on DNS.  I have not been following kernel development of
>late, so I don't know any more than what Kernel Traffic reports:

Thanks.  And everything is working again with 2.3.50.

Cheers,
Mike

-- 
My email address [EMAIL PROTECTED] above is a valid email address.
It is, in fact, a sendmail alias; the digit 'N' is incremented regularly.
Spammed aliases will be deleted.  Currently, mike[21,22]
are valid.  If email to mikeN bounces, try mikeN+1.

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

From: [EMAIL PROTECTED] (Bob Tennent)
Subject: Re: [ERROR] modprobe: can't locate module parport_lowlevel
Date: 14 Mar 2000 12:42:28 GMT
Reply-To: [EMAIL PROTECTED]

On Tue, 14 Mar 2000 05:35:52 GMT, [EMAIL PROTECTED] wrote:
 >
 >I am running redhat 6.1.  Somehow I can't get my HP 
 >LaserJet 6L to work.  The problem seems to be that modprobe
 >failed to find the low level parport driver. See the
 >start message below.
 >
 >I used 'printtool', and not surprisingly it cannot find
 >any parport device.
 >
 >On the other hand if I compile the parport and printer support
 >into kernel, everything is fine.
 >
 >Does anybody know what is wrong?
 >
Check to see that the following line is in /etc/conf.modules:

alias parport_lowlevel parport_pc

Bob T.

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

From: [EMAIL PROTECTED] (Dr H. T. Leung)
Subject: Re: Problems with NM256 module Kernel 2.2.14
Date: 14 Mar 2000 13:56:17 GMT


Strange - I don't have that message, and I have exactly the same laptop model as
yours. 

Oh, are you using Gnome/Enlightenment? I heard bad things about the Enlightenment
Sound Daemon (esd) trying to get exclusive control over the sound devices or
something like that. 

In article <[EMAIL PROTECTED]>, Thomas Gaertner <[EMAIL PROTECTED]> 
writes:
|> Hi there,
|> 
|> I 've some problems with the NM256 module using Kernel 2.2.14
|> 
|> Every time I've loaded the module an want to use it I hear strange
|> sounds and the log says: Eibe kernel: NM256: Sound palyback pointer
|> invalid!
|> 
|> I use this with the NM2200 / NM256AV chip on a sony Vaio F305.
|> Is there a way to avoid these problems?
|> 
|> -- 
|>  Thomas Gärtner
|>  Brandenburg Technical University at Cottbus
|>  Student Assistant at the Software and Systems Engineering Group
|> --
|>  >> There is not one truth only! <<
|> --
|>  PGP-Public-Key
|> http://www.informatik.tu-cottbus.de/~tgaertne/html2/public-pgp-2048.07291999.asc
|> --------------------------------------------------------------------------------

-- 
          --------------------------------------------------
"What you don't care cannot hurt you."            Chap. 7a, AMS-NS
-- 
          --------------------------------------------------
"What you don't care cannot hurt you."            Chap. 7a, AMS-NS

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

From: "Luca Garulli" <[EMAIL PROTECTED]>
Subject: INLINE methods inside (static) libraries !!!
Date: Tue, 14 Mar 2000 08:32:07 +0100

Hello,
I have a myString class with ALL methods as INLINE.
This class is used by sources that compounds the static library "pippo.a".
This class is also used by client apps that link the library.

When I compile client apps the compiler gives me "Function already defined
in xxx.o" !!!

How can I use INLINE with (static) libraries ???

Thanks, bye Lvca.




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

From: Thomas Gaertner <[EMAIL PROTECTED]>
Subject: Re: Problems with NM256 module Kernel 2.2.14
Date: Tue, 14 Mar 2000 16:35:27 +0100

Dr H. T. Leung wrote:
> 
> Strange - I don't have that message, and I have exactly the same laptop model as
> yours.
> 
> Oh, are you using Gnome/Enlightenment? I heard bad things about the Enlightenment
> Sound Daemon (esd) trying to get exclusive control over the sound devices or
> something like that.
> 
> In article <[EMAIL PROTECTED]>, Thomas Gaertner 
><[EMAIL PROTECTED]> writes:
> |> Hi there,
> |>
> |> I 've some problems with the NM256 module using Kernel 2.2.14
> |>
> |> Every time I've loaded the module an want to use it I hear strange
> |> sounds and the log says: Eibe kernel: NM256: Sound palyback pointer
> |> invalid!
> |>
> |> I use this with the NM2200 / NM256AV chip on a sony Vaio F305.
> |> Is there a way to avoid these problems?
> |>
>           --------------------------------------------------
> "What you don't care cannot hurt you."            Chap. 7a, AMS-NS

thanks for your hint...

I only use KDE-1.1.2 with OSSMixer, but this probleme seems to be
related to kernel 2.2.14.
I didn't have this before with kernel 2.2.13. I think on inserting this
module cannot dertermine which
IO, DMA and IRQ to use. After reloading these things don't happen.

-- 
 Thomas Gärtner
 Brandenburg Technical University at Cottbus
 Student Assistant at the Software and Systems Engineering Group
--
 >> There is not one truth only! <<
--
 PGP-Public-Key
http://www.informatik.tu-cottbus.de/~tgaertne/html2/public-pgp-2048.07291999.asc
================================================================================

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

From: Alan Donovan <[EMAIL PROTECTED]>
Subject: Re: underscores ????
Date: Tue, 14 Mar 2000 15:49:53 +0000

nilesh patel wrote:

> 2.  what does __typeof() do?

It's an extension to gcc giving limited provision for generic
programming (similar to templates in C++). It's a special pseudo-macro
that expands to the type of the expression given as its argument, i.e.
__typeof(new int) is int*.  Consider the "swap" macro:

#define swap(x,y)   do { __typeof(x) t = (x); x = (y); (y) = (x); }
while(0)

Without typeof, there would be no way to declare the required temporary
variable t of the correct type. The funny parentheses are another gcc
extension: scopes within macros.

typeof expansion occurs not in the preprocessor but during semantic
analysis as it requires a knowledge of types.

Type "info gcc" to lean more.

alan

-- 
========================================================================
  Alan Donovan     [EMAIL PROTECTED]    http://www.imerge.co.uk
  Imerge Ltd.      +44 1223 875265

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

Date: Tue, 14 Mar 2000 08:42:43 -0700
From: Lewis Brown <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
Crossposted-To: comp.lang.c,comp.unix.programmer
Subject: Help: Mapping complex data structs into shared memory.

Hello,

I am working with extremely large data structures (several 400 x 20,000
matricies and other junk)  that take upwards of 5 minutes to build off
of a disk.  I am debugging now and really cannot wait that long between
runs.  I have experimented with shmget, shmat, etc. hoping to create
static, quasi-persistent objects in memory that I can link to at run
time.

However, my experiments seem to show that shared pointers do not
maintain their set values after the initializing process has exited.
Below is a short example that loads a 3x3 array.

    int main() {

        const int A[3][3] = { {2,4,6}, {3,5,6},{432,3456,94872} };
        const int x = 3;
        const int y = 3;

        int i,j,k;

        int xid;
        int cid;
        size_t size;
        int flags = SVSHM_MODE | IPC_CREAT;
        key_t key;

        int **xptr;
        int  *yptr;

        // note: on my machine sizeof(int) == sizeof(int*)
        size = (x * (y+1) * sizeof(int));

         key = ftok("filename",0);
         xid = shmget(key, size, flags);
         xptr = shmat(xid,NULL,0);
         yptr = (int*)(xptr + x);

         for (i=0, k=0; i<x; i++)
             for(j=0; j<y; j++, k++)
                 yptr[k] = A[i][j];

         for(i=0, k=0; i<x; i++, k+=y)
              xptr[i] = yptr+ k;

         for (i=0; i<x; i++)
             for (j=0; j<y; j++)
                  printf("A[%d][%d] = %d\n",i,j,xptr[i][j]);   //   This
works great!

         exit(0);
    }

When I next run a similar 'reader' process, the addresses loaded into
the xptr section no longer point into the yptr section.  The array
values are still there I just have to reload xptr.

Have I overlooked something or is there another way to do this?  I can't
believe we've gone all these years without a technique that achieving
something similar to this.

Thanks for any help.

Lewis Brown

PS:  System info:  Linux RH6.0, Pentium II, gcc.

I should note that I chose to work with SysV shmget, shmat rather than
standard mmap because the processes involved are always unrelated.  I
don't have Posix sys/mman.h so didn't get to try using shm_open & mmap.
If that would solve it, where might I get a Linux/GNU compatible
version?

On the other hand, in Stevens' UNIX Nework Programming V2, he mentions
in the Posix section that different processes can have the same shared
memory mapped to different addresses in diferrent processes, which, I
suppose, could be my problem with the SysV functions as well.  If this
is the case, it would seem I'm out of luck.  What are the alternatives?


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

From: "Bass¨Ð¦õªv" <[EMAIL PROTECTED]>
Subject: linux in notebook
Date: Wed, 15 Mar 2000 00:45:59 +0800

is there anything need to pay attention when install linux in notebook ?
for excmple touchpad etc....


--
Bass said :
     I'm here .......       why....?....
I'm "WAITING" ...... here
                     For what ?
       I'm waiing ..... for you ..... so
  If You Come Here ......
         you can play me
     I promise.       ( woo !I'm coming !! )


PS : Hope Everybody LOVE "Bass"  !!!!!



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

From: [EMAIL PROTECTED] (Mike Dowling)
Subject: Re: linux in notebook
Date: 14 Mar 2000 16:55:40 GMT

On Wed, 15 Mar 2000 00:45:59 +0800, Bass¨Ð¦õªv <[EMAIL PROTECTED]> wrote:
>--
>Bass said :
>     I'm here .......       why....?....
>I'm "WAITING" ...... here
>                     For what ?
>       I'm waiing ..... for you ..... so
>  If You Come Here ......
>         you can play me
>     I promise.       ( woo !I'm coming !! )
>
>
>PS : Hope Everybody LOVE "Bass"  !!!!!

OK, I'm curious.  Who or what is Bass?

BTW, .signature files that are longer than four lines are sometimes
disdained.

Cheers,
Mike


-- 
My email address [EMAIL PROTECTED] above is a valid email address.
It is, in fact, a sendmail alias; the digit 'N' is incremented regularly.
Spammed aliases will be deleted.  Currently, mike[21,22]
are valid.  If email to mikeN bounces, try mikeN+1.

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

From: Fabrice Peix <[EMAIL PROTECTED]>
Crossposted-To: comp.lang.c,comp.unix.programmer
Subject: Re: Help: Mapping complex data structs into shared memory.
Date: Tue, 14 Mar 2000 17:56:10 +0100

Lewis Brown wrote:
> 
> Hello,
> 
> ...
> memory mapped to different addresses in diferrent processes, which, I
> suppose, could be my problem with the SysV functions as well.  If this
> is the case, it would seem I'm out of luck.  What are the alternatives?

        Yop,

You must check return value for errors perhaps is a permissions problem
(In fact you must always checks return of functions ....)

        Ooops and Good Luck.

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


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