Linux-Development-Sys Digest #967, Volume #6 Fri, 16 Jul 99 11:14:01 EDT
Contents:
Re: DMA from/to user space? (Robert Kaiser)
mpeg-1 decode routine (Eelco Grakist)
Re: OLE in Linux? (Habin)
has no current->timeout structure in kernel 2.2.X? ("robert_c")
Re: New OS development (Alex Wells)
Re: Bug of GCC (Peter Allen)
Re: Bug of GCC (Peter Allen)
Re: DMA from/to user space? (Robert Kaiser)
Re: has no current->timeout structure in kernel 2.2.X? ("Moors, ing. E.W.J.")
Re: OLE in Linux? (Peter Allen)
Re: DMA from/to user space? (Maciej Golebiewski)
Re: Bug of GCC (Marcus Sundberg)
modem still won't work (Ranger)
Re: Bug of GCC (Ian Wild)
Re: Bug of GCC (Scott Lanning)
How can I log kernel message? (kimgh)
Re: Bug of GCC (Scott Lanning)
Makefiles for multiple programmers (Randy Galliher)
Re: Bug of GCC (Scott Lanning)
Re: Bug of GCC (Scott Lanning)
----------------------------------------------------------------------------
From: [EMAIL PROTECTED] (Robert Kaiser)
Subject: Re: DMA from/to user space?
Date: 16 Jul 1999 09:12:04 GMT
In article <[EMAIL PROTECTED]>,
Maciej Golebiewski <[EMAIL PROTECTED]> writes:
> Robert Kaiser wrote:
>>
>> Funny though, almost every virtual memory OS except Linux does support
>> user-space DMA (e.g. AIX, NT, ...). Why Linus thinks it's such a bad
>> thing is beyond me.
>>
>> Have a look at ftp://ftp.sysgo.de/pub/Linux. You'll find a very simple
>> kernel patch there that will allow you to do just what you want --
>> scatter/gather DMA directly from/to user-space memory.
>
> M-VIA from Berkeley has a similar feature (among others). They don't
> patch the kernel, but implement locking/unlocking memory in a kernel
> module. Very comfortable. I'm using this with 2.2.5 and it works
> great.
>
That's interesting news! I'll look up their stuff and see how they do
it. In an early version of my patch, I also had everything in a module,
but to do that, I found that I had to duplicate a lot of code from the
kernel into my module. I didn't like that, so I preferred to patch the
kernel instead. The kernel already has 95% of the required code in it,
there really is very little to add (see my patch for details).
IMHO, this kind of functionality should be in the standard kernel.
Anything else (patch or module) is a kludge.
Rob
================================================================
Robert Kaiser email: rkaiser AT sysgo DOT de
SYSGO RTS GmbH
Mainz / Germany
------------------------------
From: Eelco Grakist <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps
Subject: mpeg-1 decode routine
Date: Fri, 16 Jul 1999 11:37:36 +0200
Reply-To: Eelco Grakist <[EMAIL PROTECTED]>
Hi y'all
does anybody know about a c-source (or api) to decode an mpeg1 stream?
(like an AVI file)
I triend mptv-sdk, but this is an api to decode AND play the stream. But
I don't need the play part, I just need the uncompressed frames.
I don't think I want to write a realtime mpeg1 decoder myself...
Thanks in advance for your undoubtfully helpfull replies!
Eelco
PS> could you please respond to the group and also to my email address?
I don't trust my news-server very much... :-(
------------------------------
From: Habin <[EMAIL PROTECTED]>
Subject: Re: OLE in Linux?
Date: Fri, 16 Jul 1999 08:00:27 GMT
> I thought that all gnome apps supported the com superset orbs, so
> any native gnome apps should have com features, therefore ole.
>
> Peter Allen
>
Microsoft define COM as Component Object Model.
OLE as Object Linking Embedding.
COM and OLE share some common part. For example, interface
definition: Every interface's root is IUnknown abstract class.
COM guarantees OLE? I don't think so. Microsoft separates COM and
OLE in API level. I only know that porting COM application into
OLE is not easy task.
I thought that OLE is new technologies but it wasn't. Few people
do OLE.
Blue Skies~
Habin
--
Software Engineer (VC++, Linux)
Skydiver (FAI certificate, total freefall time is
50m 45s)
Company URL is "http://www.mizi.co.kr"
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
From: "robert_c" <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps,comp.os.linux.hardware
Subject: has no current->timeout structure in kernel 2.2.X?
Date: 16 Jul 1999 09:47:20 GMT
Hi:
I have a problem in porting code from kernel 2.0.X to 2.2.X.
In 2.0.X, I need a blocking function to do time deleayed and it was
implemented like following .
(Delay 3 second)
...
...
int delay_second = 3;
unsigned long total_jiffies = jiffies + delay_second *HZ;
...
current->timeout = total_jiffies; //<-- has no current->timeout data
structure in kernel 2.2.X?
current->state = TASK_INTERRUPTIBLE;
schedule();
current->timeout = 0; // (reset the timeout) the error like above, <-- has
no current->timeout data structure in kernel 2.2.X?
...
...
...
But, while I compile in kernel 2.2.X, it always says (structure *current has
no member named "timeout")
My question is that the 2.2.X kernel has some other API (or data
structure, like global variable) to do something like above? If yes, how to
do that?
------------------------------
From: Alex Wells <[EMAIL PROTECTED]>
Subject: Re: New OS development
Date: Fri, 16 Jul 1999 11:12:59 +0100
Reply-To: [EMAIL PROTECTED]
Hi all,
Just to let you know - I may not be able to see the newsgroup soon, so can
you post to [EMAIL PROTECTED] as well as to the newsgroup.
Thanx In Advance,
Alex
--
Of all the things I've lost, I miss my mind the most
-- Ozzy Ozbourne
Veni, Vermini, Vomui - I came, I got Ratted, I Threw up.
------------------------------
From: Peter Allen <[EMAIL PROTECTED]>
Subject: Re: Bug of GCC
Date: Fri, 16 Jul 1999 11:18:06 +0100
Cute Panda wrote:
>
> Ulrich Drepper ���g��峹 ...
> >"Cute Panda" <[EMAIL PROTECTED]> writes:
> >
> >> I'm using RedHat Linux 6.0, 4CD Full Package, I encounter a bug of gcc
> as
> >> follows:
> >
> >This is no bug in gcc, it's a bug in your program.
> >
> >--
> >---------------. drepper at gnu.org ,-. 1325 Chesapeake Terrace
> >Ulrich Drepper \ ,-------------------' \ Sunnyvale, CA 94089 USA
> >Cygnus Solutions `--' drepper at cygnus.com `------------------------
>
> Lots of preprocessors, like MS VC++, Sunsoft Workshop, IBM and HP, they
> don't complain about
> "#if 0 ... It's a bug .... #endif", only gnu preprocessor complains about
> this code.
Doesn't that say something to you about how ansi compliant they are?
Peter Allen
------------------------------
From: Peter Allen <[EMAIL PROTECTED]>
Subject: Re: Bug of GCC
Date: Fri, 16 Jul 1999 11:20:53 +0100
Scott Lanning wrote:
>
> Cute Panda ([EMAIL PROTECTED]) wrote:
> : if gcc preprocessor is able to recognize "#if 0", then it should
> : know that all the following code before #endif is not real code and
> : should not be tokenized, why is it necessary to break the text into
> : tokens ? don't you think tokenizing the text inside #if 0 ... #endif
> : is a redundant job ?
>
> Yeah, I agree with you. I think some people are more concerned with
> sticking to a familiar, "elegant" system rather than one which is
> more practical. (Sometimes I'm one of them.. :( )
>
> Anyway, I have another example of how the GNU preprocessor ignores the
> standard. In the syntax of conditionals (section 1.5.2 in GNU manual)
>
> #if expression
> controlled text
> #endif /* expression */
>
> Then it says, "In fact, you can put anything at all after the
> `#endif' and it will be ignored by the GNU C preprocessor, but only
> comments are acceptable in ANSI Standard C." So, please don't
> give arguments based on the high moral ground of the GNU C
> preprocessor because it conforms to "standard" C.
>
> --
> Scott Lanning: [EMAIL PROTECTED], http://physics.bu.edu/~slanning
> "I'm going to have fun telling you about this absurdity, because I
> find it delightful." --Richard Feynman
As the standard is there it is best to comply to it in case anyone wants
to port your code. Have you ever ported something which has _loads_ of
errors about one thing like that that all need to be changed, when if
the original author had just followed the standard everything would be
fine.
Peter Allen
------------------------------
From: [EMAIL PROTECTED] (Robert Kaiser)
Subject: Re: DMA from/to user space?
Date: 16 Jul 1999 09:17:18 GMT
In article <[EMAIL PROTECTED]>,
Clark Williams <[EMAIL PROTECTED]> writes:
> My intent is to lock down the pages that form the buffer specified by a
> read/write request and DMA to/from them using scatter-gather. One question
> I've got is: do I have to be back in process context to unlock them? Or will
> it be safe to do so from interrupt context?
>
No, you'll have to be back in the process context.
Rob
================================================================
Robert Kaiser email: rkaiser AT sysgo DOT de
SYSGO RTS GmbH
Mainz / Germany
------------------------------
Crossposted-To: comp.os.linux.development.apps,comp.os.linux.hardware
From: "Moors, ing. E.W.J." <[EMAIL PROTECTED]>
Subject: Re: has no current->timeout structure in kernel 2.2.X?
Date: Fri, 16 Jul 1999 10:26:21 GMT
robert_c wrote:
>
> Hi:
> I have a problem in porting code from kernel 2.0.X to 2.2.X.
> In 2.0.X, I need a blocking function to do time deleayed and it was
> implemented like following .
>
> (Delay 3 second)
> ...
> ...
> int delay_second = 3;
> unsigned long total_jiffies = jiffies + delay_second *HZ;
> ...
>
> current->timeout = total_jiffies; //<-- has no current->timeout data
> structure in kernel 2.2.X?
> current->state = TASK_INTERRUPTIBLE;
> schedule();
> current->timeout = 0; // (reset the timeout) the error like above, <-- has
> no current->timeout data structure in kernel 2.2.X?
> ...
> ...
> ...
>
> But, while I compile in kernel 2.2.X, it always says (structure *current has
> no member named "timeout")
>
> My question is that the 2.2.X kernel has some other API (or data
> structure, like global variable) to do something like above? If yes, how to
> do that?
I ran in to the same problem as you did, the new calls are
current->state = TASK_INTERRUPTIBLE;
schedule_timeout(JIFFIES);
Eric
------------------------------
From: Peter Allen <[EMAIL PROTECTED]>
Subject: Re: OLE in Linux?
Date: Fri, 16 Jul 1999 11:27:08 +0100
Christopher Browne wrote:
>
> On Thu, 15 Jul 1999 20:10:07 +0100, Peter Allen
> <[EMAIL PROTECTED]> wrote:
> >I thought that all gnome apps supported the com superset orbs, so any
> >native gnome apps should have com features, therefore ole.
>
> "COM Superset ORBs?"
Woops, that was me thinking faster than I can type, so I put the COM
first instead of second :-)
> What on earth is that?
>
> Can you provide a URL link to some reference to that?
>
> It's fair to say that GNOME has the *intent* to provide a CORBA-based
> analogue to OLE. (They call it "BABOON" - "BABOON Allows BABOON Objects
> Over Networks.")
>
> There is some code written; I've been monitoring the Gnumeric mailing
> list, and it is one of the early apps that is being made to support
> BABOON.
>
> The notion that this has anything *directly* to do with COM or OLE is
> quite mistaken. You *might* be able to bridge using a CORBA-to-DCOM
> adaptor to some DCOM code, but I seriously doubt that anybody has tried
> such.
I have to admit I know nothing about ORBs, COM, OLE or anything like
that.
I have no reason to program them so don't. :-)
I just read somewhere on gnome.org that gnome uses an object request
broker,
which is a superset of com, and the person in the previous message had
said
they were related. Maybe it was a bad idea to post....
Peter Allen
------------------------------
From: Maciej Golebiewski <[EMAIL PROTECTED]>
Subject: Re: DMA from/to user space?
Date: Fri, 16 Jul 1999 12:33:08 +0200
Robert Kaiser wrote:
> IMHO, this kind of functionality should be in the standard kernel.
> Anything else (patch or module) is a kludge.
I don't know. This (standard part of kernel) is not entirely safe:
a rogue application might lock a significant part of physical RAM
and bring the system to its knees. Of course it's still possible
with a loadable module, but the requirement for installing this
module might be a kind of a warning light to the user, that an
application might pose some threats to the system.
Maciej
------------------------------
From: Marcus Sundberg <[EMAIL PROTECTED]>
Subject: Re: Bug of GCC
Date: Fri, 16 Jul 1999 13:28:27 +0200
Cute Panda wrote:
>
> If it's the way ANSI C is specified, then why the other preprocessor
> don't suffer this
> problem ? they don't meet the ANSCI standard, right ?
>
> Many books talk about this code and say it's a simple way to make
> comments, and lots of
> programmers write their code like this, well, I think it's very inconvenient
> for some people
> to modify their code just because gcc preprocessor complains about this kind
> of code.
If they hadn't written broken piece-of-crap code they wouldn't have to
modify it. If you write non standard-compliant code and then complain
about porting it being inconvenient you should probably stay off coding
entirely.
//Marcus
--
===============================+====================================
Marcus Sundberg | http://www.stacken.kth.se/~mackan/
Royal Institute of Technology | Phone: +46 707 295404
Stockholm, Sweden | E-Mail: [EMAIL PROTECTED]
------------------------------
From: Ranger <[EMAIL PROTECTED]>
Subject: modem still won't work
Date: Fri, 16 Jul 1999 08:19:24 -0400
ok here is the stats : I have a USR faxmodem (standard sportster in an
ISA slot 56k) I am useing Linux Mandrake 6.0 . I have an E-machine 366i
pc
366 cleron
32mg ram
24x cd
4.1 gig hard drive (1.6 gig partitioned off for linux )
this is the problem: when I try to connect to the internet useing Kppp
it telles me my modem is busy and minicom tells my my modem is locked (I
have the modem set up on /dev/ttyS1 ) in windoze I have the modem on com
2 and irq 10
what I have tried so far: 1.switching to /dev/cua1 (no difference
)...2.removed .kde/share/config/kppprc and trying to redo the setup
....3.tried to see if there was a ppp0.pid file (there was none)
...4.looked in /var/lock for anything that might be locking the modem (I
don't really know that much about linux so I didn't really know what I
was looking at )I didn't find anything labled "modem".....5.someone
recomended using isapnp but I don't know the propper comands
(help!).......6. someone said something about a setserial command ( same
problem with this as in 5
i would like thank those wha have been trying to help I hope this
information will you ..help me get this resolved ..I refuse to give in
....To Concede The Possibility Of Defeat Is To Put Yourself Halfway
There
besides isn't this what open soure is about finding problem fixing them
and makeing it stronger after you have ?
------------------------------
From: Ian Wild <[EMAIL PROTECTED]>
Subject: Re: Bug of GCC
Date: Fri, 16 Jul 1999 15:14:45 +0200
Scott Lanning wrote:
>
> Marcus Sundberg ([EMAIL PROTECTED]) wrote:
> : If they hadn't written broken piece-of-crap code they wouldn't have
> : to modify it. If you write non standard-compliant code and then
> : complain about porting it being inconvenient you should probably
> : stay off coding entirely.
>
> How in your mind did you twist "If *they* hadn't written broken
> piece-of-crap code" to "If *you* write non standard-compliant code"?
Hmmm....my understanding of English suggests that
the pronoun "you" can be, and often is, used as a
generic placeholder, without necessarily being a
direct reference to the person being addressed. Much
like "one", but carrying no hint that the speaker
is, in fact, Her Britannic Majesty.
FWIW, and straying dangerously close to being on-topic,
I'm also of the opinion that compilers should complain
at every opportunity about non-standard code. The fact
that gcc allows *some* wrong-doing, like end-of-line
noise on a #endif, is no justification for breaking it
yet further.
------------------------------
From: [EMAIL PROTECTED] (Scott Lanning)
Subject: Re: Bug of GCC
Date: 16 Jul 1999 13:21:01 GMT
Peter Allen ([EMAIL PROTECTED]) wrote:
: Scott Lanning wrote:
: > Then it says, "In fact, you can put anything at all after the
: > `#endif' and it will be ignored by the GNU C preprocessor, but
: > only comments are acceptable in ANSI Standard C." So, please
: > don't give arguments based on the high moral ground of the GNU C
: > preprocessor because it conforms to "standard" C.
:
: As the standard is there it is best to comply to it in case anyone
: wants to port your code. Have you ever ported something which has
: _loads_ of errors about one thing like that that all need to be
: changed, when if the original author had just followed the standard
: everything would be fine.
I understand your concerns, Mr. Allen, and I do wish people would
code more cleanly, however my argument is not about whether one
should conform to standard C. I agree with that, in general.
Okay, let me recapitulate...
1) Cute Panda wondered why the GNU C preprocessor doesn't allow
you put an apostrophe inside an #if 0 .. #endif.
2) The reply was based on the premise that, it is not allowed
by standard C.
3) I argued with that premise, giving examples in which the
GNU C preprocessor doesn't conform to standard C.
If an argument is based on false premises, then the argument
is invalid. This is basic logic. I thought it was generally
accepted that one uses logic when debating things, but,
I guess I forgot I was on Usenet. My bad...
I don't know, maybe I'm delusional or so moronic that I
can't see that I'm babbling. It is like I live in another
universe or something. Maybe that's why nobody will give
me a job. :( I think I need to get away for a while. Or
start doing drugs.. Anyone know of any good drugs?
--
Scott Lanning: [EMAIL PROTECTED], http://physics.bu.edu/~slanning
"One should not confuse this craving for change and novelty with the
indifference of play which is in its greatest levity at the same time
the most sublime and indeed the only true seriousness." --Georg Hegel
------------------------------
From: kimgh <[EMAIL PROTECTED]>
Subject: How can I log kernel message?
Date: Fri, 16 Jul 1999 22:11:30 +0900
Hi all
I know that kernel message is logged in syslog.
But syslog cannot log all kernel message.
How can I log kernel message without lost any kernel message?
Best regards.
------------------------------
From: [EMAIL PROTECTED] (Scott Lanning)
Subject: Re: Bug of GCC
Date: 16 Jul 1999 14:05:32 GMT
Ian Wild ([EMAIL PROTECTED]) wrote:
: Scott Lanning wrote:
: > Marcus Sundberg ([EMAIL PROTECTED]) wrote:
: > : If they hadn't written broken piece-of-crap code they wouldn't have
: > : to modify it. If you write non standard-compliant code and then
: > : complain about porting it being inconvenient you should probably
: > : stay off coding entirely.
: > How in your mind did you twist "If *they* hadn't written broken
: > piece-of-crap code" to "If *you* write non standard-compliant code"?
:
: Hmmm....my understanding of English suggests that
: the pronoun "you" can be, and often is, used as a
: generic placeholder, without necessarily being a
: direct reference to the person being addressed.
Your understanding of the pronoun "you" is correct. However, in the
above context it seemed to me he was referring to Cute Panda.
Maybe he meant it in the general case, though, and I apologize
if he did.
: Much like "one", but carrying no hint that the speaker
: is, in fact, Her Britannic Majesty.
I think you meant "we", but it was a good joke anyway.
: FWIW, and straying dangerously close to being on-topic,
Yeah, I'm sorry, I forgot it was c.o.l.d.s.
: I'm also of the opinion that compilers should complain
: at every opportunity about non-standard code. The fact
: that gcc allows *some* wrong-doing, like end-of-line
: noise on a #endif, is no justification for breaking it
: yet further.
That is true. If it is consistent then it is okay.
Then maybe I'd complain that the C standard was bogus.
But, as fun as I'm sure that would be.....
--
Scott Lanning: [EMAIL PROTECTED], http://physics.bu.edu/~slanning
"If lightning is the anger of the gods, the gods are concerned mostly
with trees." --Lao Tse
------------------------------
From: Randy Galliher <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps
Subject: Makefiles for multiple programmers
Date: Fri, 16 Jul 1999 13:31:03 GMT
Is there an optimal makefile for a large software project involving
several programmers. It is desireable to have the baseline source in a
separate directory with the objects stored in libraries. This would
allow each programmer to build and test their own version of the project.
I have been looking for a "how-to" or an example of a makefile that does
this already, but have found none on the net.
================== Posted via SearchLinux ==================
http://www.searchlinux.com
------------------------------
From: [EMAIL PROTECTED] (Scott Lanning)
Subject: Re: Bug of GCC
Date: 16 Jul 1999 12:47:12 GMT
Marcus Sundberg ([EMAIL PROTECTED]) wrote:
: If they hadn't written broken piece-of-crap code they wouldn't have
: to modify it. If you write non standard-compliant code and then
: complain about porting it being inconvenient you should probably
: stay off coding entirely.
How in your mind did you twist "If *they* hadn't written broken
piece-of-crap code" to "If *you* write non standard-compliant code"?
I'm sure it was convenient to your argument, and I understand you
have some insecurities about your manhood[1], but I wish you would
stop ad hominem arguments against Cute Panda. It is a glaring
phallicism, er, uh, I mean fallacy..
[1] Hello McFly, I know I'm using an ad hominem attack...
--
Scott Lanning: [EMAIL PROTECTED], http://physics.bu.edu/~slanning
"I'm going to have fun telling you about this absurdity, because I
find it delightful." --Richard Feynman
------------------------------
From: [EMAIL PROTECTED] (Scott Lanning)
Subject: Re: Bug of GCC
Date: 16 Jul 1999 14:37:18 GMT
Ian Wild ([EMAIL PROTECTED]) wrote:
: Let's generalise it:
: 1) Why doesn't gcc have <arbitrary feature>?
: 2) Becuase it's trying to be a C compiler, not
: a <xyzzy>.
: 3) Nonsense - there's at least one place where it
: deviates from an ideal C compiler, so it should have
: all possible features.
:
: Even less convincing.
It is true that the argument you showed is not very convincing,
but I claim it is a straw man and not what I argued (maybe
I was confusing?). For number 3, I would put (awkwardly):
3) Nonsense - there's at least one place where it
deviates from an ideal C compiler, so it is not valid
to argue that ( gcc doesn't have <arbitrary feature>
because it's trying to be a C compiler, not a <xyzzy> ) .
I don't claim that it should have all possible features.
Okay, I think it should allow apostrophes inside a false
conditional, but I don't think my argument depends on that;
it is true that allowing apostrophes is not standard C and
should not be allowed. If gcc is trying to be a C compiler,
then why does it deviate from C? Because it is convenient
to deviate from C in some cases. That is not to say that it
is wise or portable to deviate from the C standard, but it is
the case that it does. Therefore claiming that it doesn't
have a certain feature based on the fact that it is a
C compiler is bogus, IMHO.
: > If an argument is based on false premises, then the argument
: > is invalid. This is basic logic.
:
: I think you'd better go check your logic textbooks.
: An argument's validity is a formal property, and cannot,
: therefore, be based on any interpretation of the premises.
You're right, sorry, I used the wrong word. It should've said,
"If an argument is based on false premises, then the *conclusion*
is invalid."
: > I think I need to get away for a while. Or
: > start doing drugs.. Anyone know of any good drugs?
:
: RTFPharmocopia
:)
--
Scott Lanning: [EMAIL PROTECTED], http://physics.bu.edu/~slanning
"I'm going to have fun telling you about this absurdity, because I
find it delightful." --Richard Feynman
------------------------------
** 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
******************************