LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* assembly code in the loadable kernel module
@ 2007-04-27  8:45 Parav K Pandit
  2007-04-27  9:40 ` Jan Engelhardt
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Parav K Pandit @ 2007-04-27  8:45 UTC (permalink / raw)
  To: linux-kernel

Hi,

I have written one function in assembly for my kernel module.
Function is in module3.s file.
I have added the module3.o file in the object list in the Makefile.
But it shows compile time warning and following output.

What do I need to do to compile assembly code in my kernel module.

CC [M]  /home/parav/cache_improve/test_module/module1.o
CC [M]  /home/parav/cache_improve/test_module/module2.o
as -a32 -o /home/parav/cache_improve/test_module/module3.o
/home/parav/cache_improve/test_module/module3.s
LD [M]  /home/parav/cache_improve/test_module/sdk3_module.o
Building modules, stage 2.
MODPOST
Warning: could not find /home/parav/cache_improve/test_module/.module3.o.cmd
for /home/parav/cache_improve/test_module/module3.o
*** Warning: "test_func"
[/home/parav/cache_improve/test_module/sdk3_module.ko] undefined!
*** Warning: "" [/home/parav/cache_improve/test_module/sdk3_module.ko]
undefined!

I expect CC[M] kind of command for the module3.o file also so that
.module3.o.cmd file gets generated.

Regards,
Parav Pandit



DISCLAIMER:
This message (including attachment if any) is confidential and may be privileged. Before opening attachments please check them for viruses and defects. MindTree Consulting Limited (MindTree) will not be responsible for any viruses or defects or any forwarded attachments emanating either from within MindTree or outside. If you have received this message by mistake please notify the sender by return  e-mail and delete this message from your system. Any unauthorized use or dissemination of this message in whole or in part is strictly prohibited.  Please note that e-mails are susceptible to change and MindTree shall not be liable for any improper, untimely or incomplete transmission.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: assembly code in the loadable kernel module
  2007-04-27  8:45 assembly code in the loadable kernel module Parav K Pandit
@ 2007-04-27  9:40 ` Jan Engelhardt
  2007-04-27 10:59 ` Sam Ravnborg
  2007-04-27 11:27 ` linux-os (Dick Johnson)
  2 siblings, 0 replies; 11+ messages in thread
From: Jan Engelhardt @ 2007-04-27  9:40 UTC (permalink / raw)
  To: Parav K Pandit; +Cc: linux-kernel


On Apr 27 2007 14:15, Parav K Pandit wrote:
>
>I have written one function in assembly for my kernel module.
>Function is in module3.s file.
>I have added the module3.o file in the object list in the Makefile.
>But it shows compile time warning and following output.
>
>What do I need to do to compile assembly code in my kernel module.

A proper Makefile entry would be a start. Post it, let's find the error.

Jan
-- 

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: assembly code in the loadable kernel module
  2007-04-27  8:45 assembly code in the loadable kernel module Parav K Pandit
  2007-04-27  9:40 ` Jan Engelhardt
@ 2007-04-27 10:59 ` Sam Ravnborg
  2007-04-27 11:27 ` linux-os (Dick Johnson)
  2 siblings, 0 replies; 11+ messages in thread
From: Sam Ravnborg @ 2007-04-27 10:59 UTC (permalink / raw)
  To: Parav K Pandit; +Cc: linux-kernel

On Fri, Apr 27, 2007 at 02:15:48PM +0530, Parav K Pandit wrote:
> Hi,
> 
> I have written one function in assembly for my kernel module.
> Function is in module3.s file.
In the kernel assembeler files are named .S and preprocessed.
Try renaming it module3.S then it should work.

	Sam

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: assembly code in the loadable kernel module
  2007-04-27  8:45 assembly code in the loadable kernel module Parav K Pandit
  2007-04-27  9:40 ` Jan Engelhardt
  2007-04-27 10:59 ` Sam Ravnborg
@ 2007-04-27 11:27 ` linux-os (Dick Johnson)
  2007-04-27 11:57   ` Marat Buharov
  2 siblings, 1 reply; 11+ messages in thread
From: linux-os (Dick Johnson) @ 2007-04-27 11:27 UTC (permalink / raw)
  To: Parav K Pandit; +Cc: linux-kernel


On Fri, 27 Apr 2007, Parav K Pandit wrote:

> Hi,
>
> I have written one function in assembly for my kernel module.
> Function is in module3.s file.
> I have added the module3.o file in the object list in the Makefile.
> But it shows compile time warning and following output.
>
> What do I need to do to compile assembly code in my kernel module.
>
> CC [M]  /home/parav/cache_improve/test_module/module1.o
> CC [M]  /home/parav/cache_improve/test_module/module2.o
> as -a32 -o /home/parav/cache_improve/test_module/module3.o
> /home/parav/cache_improve/test_module/module3.s
> LD [M]  /home/parav/cache_improve/test_module/sdk3_module.o
> Building modules, stage 2.
> MODPOST
> Warning: could not find /home/parav/cache_improve/test_module/.module3.o.cmd
> for /home/parav/cache_improve/test_module/module3.o
> *** Warning: "test_func"
> [/home/parav/cache_improve/test_module/sdk3_module.ko] undefined!
> *** Warning: "" [/home/parav/cache_improve/test_module/sdk3_module.ko]
> undefined!
>
> I expect CC[M] kind of command for the module3.o file also so that
> .module3.o.cmd file gets generated.
>
> Regards,
> Parav Pandit

Just name the source module3.S
                              ^______ not .s
>

Cheers,
Dick Johnson
Penguin : Linux version 2.6.16.24 on an i686 machine (5592.62 BogoMips).
New book: http://www.AbominableFirebug.com/
_
\x1a\x04

****************************************************************
The information transmitted in this message is confidential and may be privileged.  Any review, retransmission, dissemination, or other use of this information by persons or entities other than the intended recipient is prohibited.  If you are not the intended recipient, please notify Analogic Corporation immediately - by replying to this message or by sending an email to DeliveryErrors@analogic.com - and destroy all copies of this information, including any attachments, without reading or disclosing them.

Thank you.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: assembly code in the loadable kernel module
  2007-04-27 11:27 ` linux-os (Dick Johnson)
@ 2007-04-27 11:57   ` Marat Buharov
  2007-04-27 12:11     ` Robert P. J. Day
  2007-04-27 16:12     ` Daniel Hazelton
  0 siblings, 2 replies; 11+ messages in thread
From: Marat Buharov @ 2007-04-27 11:57 UTC (permalink / raw)
  To: linux-os (Dick Johnson); +Cc: Parav K Pandit, linux-kernel

On 4/27/07, Parav K Pandit <Parav_Pandit@mindtree.com> wrote:
> DISCLAIMER:
> This message (including attachment if any) is confidential and may be privileged. Before opening attachments please check them for viruses and defects. MindTree Consulting Limited (MindTree) will not be responsible for any viruses or defects or any forwarded attachments emanating either from within MindTree or outside. If you have received this message by mistake please notify the sender by return  e-mail and delete this message from your system. Any unauthorized use or dissemination of this message in whole or in part is strictly prohibited.  Please note that e-mails are susceptible to change and MindTree shall not be liable for any improper, untimely or incomplete transmission.

On 4/27/07, linux-os (Dick Johnson) <linux-os@analogic.com> wrote:
> ****************************************************************
> The information transmitted in this message is confidential and may be privileged.  Any review, retransmission, dissemination, or other use of this information by persons or entities other than the intended recipient is prohibited.  If you are not the intended recipient, please notify Analogic Corporation immediately - by replying to this message or by sending an email to DeliveryErrors@analogic.com - and destroy all copies of this information, including any attachments, without reading or disclosing them.

Damn, people. Please, remove that sort of disclaimers (about
confidential information) while posting to public mailing lists.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: assembly code in the loadable kernel module
  2007-04-27 11:57   ` Marat Buharov
@ 2007-04-27 12:11     ` Robert P. J. Day
  2007-04-27 16:12     ` Daniel Hazelton
  1 sibling, 0 replies; 11+ messages in thread
From: Robert P. J. Day @ 2007-04-27 12:11 UTC (permalink / raw)
  To: Marat Buharov; +Cc: linux-os (Dick Johnson), Parav K Pandit, linux-kernel

On Fri, 27 Apr 2007, Marat Buharov wrote:

> On 4/27/07, Parav K Pandit <Parav_Pandit@mindtree.com> wrote:
> > DISCLAIMER:
> > This message (including attachment if any) is confidential and may be
> > privileged. Before opening attachments please check them for viruses and
> > defects. MindTree Consulting Limited (MindTree) will not be responsible for
> > any viruses or defects or any forwarded attachments emanating either from
> > within MindTree or outside. If you have received this message by mistake
> > please notify the sender by return  e-mail and delete this message from your
> > system. Any unauthorized use or dissemination of this message in whole or in
> > part is strictly prohibited.  Please note that e-mails are susceptible to
> > change and MindTree shall not be liable for any improper, untimely or
> > incomplete transmission.
>
> On 4/27/07, linux-os (Dick Johnson) <linux-os@analogic.com> wrote:
> > ****************************************************************
> > The information transmitted in this message is confidential and may be
> > privileged.  Any review, retransmission, dissemination, or other use of this
> > information by persons or entities other than the intended recipient is
> > prohibited.  If you are not the intended recipient, please notify Analogic
> > Corporation immediately - by replying to this message or by sending an email
> > to DeliveryErrors@analogic.com - and destroy all copies of this information,
> > including any attachments, without reading or disclosing them.
>
> Damn, people. Please, remove that sort of disclaimers (about
> confidential information) while posting to public mailing lists.

good luck.  this issue comes up on a regular basis on mailing lists
all over the place and the response is always the same -- some
companies, based on the advice of their legal departments, absolutely
*require* those rambling, worthless disclaimers, and the senders have
no ability whatsoever to turn them off.

there is only one solution to that sort of thing -- blacklist the
entire sending domain until they get a clue.  yes, it's draconian, but
there's really no other way to educate them.

rday
-- 
========================================================================
Robert P. J. Day
Linux Consulting, Training and Annoying Kernel Pedantry
Waterloo, Ontario, CANADA

http://fsdev.net/wiki/index.php?title=Main_Page
========================================================================

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: assembly code in the loadable kernel module
  2007-04-27 11:57   ` Marat Buharov
  2007-04-27 12:11     ` Robert P. J. Day
@ 2007-04-27 16:12     ` Daniel Hazelton
  2007-04-27 21:06       ` linux-os (Dick Johnson)
  2007-04-27 21:31       ` Lee Revell
  1 sibling, 2 replies; 11+ messages in thread
From: Daniel Hazelton @ 2007-04-27 16:12 UTC (permalink / raw)
  To: Marat Buharov; +Cc: linux-os (Dick Johnson), Parav K Pandit, linux-kernel

On Friday 27 April 2007 07:57:58 Marat Buharov wrote:
> On 4/27/07, Parav K Pandit <Parav_Pandit@mindtree.com> wrote:
> > DISCLAIMER:
> > This message (including attachment if any) is confidential and may be
> > privileged. Before opening attachments please check them for viruses and
> > defects. MindTree Consulting Limited (MindTree) will not be responsible
> > for any viruses or defects or any forwarded attachments emanating either
> > from within MindTree or outside. If you have received this message by
> > mistake please notify the sender by return  e-mail and delete this
> > message from your system. Any unauthorized use or dissemination of this
> > message in whole or in part is strictly prohibited.  Please note that
> > e-mails are susceptible to change and MindTree shall not be liable for
> > any improper, untimely or incomplete transmission.
>
> On 4/27/07, linux-os (Dick Johnson) <linux-os@analogic.com> wrote:
> > ****************************************************************
> > The information transmitted in this message is confidential and may be
> > privileged.  Any review, retransmission, dissemination, or other use of
> > this information by persons or entities other than the intended recipient
> > is prohibited.  If you are not the intended recipient, please notify
> > Analogic Corporation immediately - by replying to this message or by
> > sending an email to DeliveryErrors@analogic.com - and destroy all copies
> > of this information, including any attachments, without reading or
> > disclosing them.
>
> Damn, people. Please, remove that sort of disclaimers (about
> confidential information) while posting to public mailing lists.

Most companies require that *ANY* e-mail sent by employees while at work 
contain disclaimers like those. Some of them even have their mail servers 
*automatically* attach those footers.

DRH

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: assembly code in the loadable kernel module
  2007-04-27 16:12     ` Daniel Hazelton
@ 2007-04-27 21:06       ` linux-os (Dick Johnson)
  2007-05-01 13:08         ` Valdis.Kletnieks
  2007-04-27 21:31       ` Lee Revell
  1 sibling, 1 reply; 11+ messages in thread
From: linux-os (Dick Johnson) @ 2007-04-27 21:06 UTC (permalink / raw)
  To: Daniel Hazelton; +Cc: Marat Buharov, Parav K Pandit, linux-kernel


On Fri, 27 Apr 2007, Daniel Hazelton wrote:
> On Friday 27 April 2007 07:57:58 Marat Buharov wrote:
>> On 4/27/07, Parav K Pandit <Parav_Pandit@mindtree.com> wrote:
[SNIPPED all the junk]
>
> Most companies require that *ANY* e-mail sent by employees while at work
> contain disclaimers like those. Some of them even have their mail servers
> *automatically* attach those footers.
>
> DRH
>

Yes, it's getting to be widespread. However, there is a way around it for
facilities like the linux-kernel list. Everybody could put a ^D or ^Z at
the end of their .sig . Then the list-server software could filter it like:
-----------
//
// Free software
//
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>

int main(void);
int main()
{
     char buf[0x400];
     for(;;)
     {
        if(!fgets(buf, sizeof(buf), stdin) || feof(stdin))
            break;
        fprintf(stdout, buf);
        if(strchr(buf, 'Z'-64) || strchr(buf, 'D'-64))
            break;
     }
     return 0;
}
---------
Anything after ^D or ^Z doesn't get copied to the list. Something like
this needs to be done because it's gonna get a whole lot worse because
all the 'IT' people read the same rags -- so they think that "naked"
email fails the "due diligence" test. Honest, I'm not making that up!

Cheers,
Dick Johnson
Penguin : Linux version 2.6.16.24 on an i686 machine (5592.62 BogoMips).
New book: http://www.AbominableFirebug.com/
_
\x1a\x04


****************************************************************
The information transmitted in this message is confidential and may be privileged.  Any review, retransmission, dissemination, or other use of this information by persons or entities other than the intended recipient is prohibited.  If you are not the intended recipient, please notify Analogic Corporation immediately - by replying to this message or by sending an email to DeliveryErrors@analogic.com - and destroy all copies of this information, including any attachments, without reading or disclosing them.

Thank you.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: assembly code in the loadable kernel module
  2007-04-27 16:12     ` Daniel Hazelton
  2007-04-27 21:06       ` linux-os (Dick Johnson)
@ 2007-04-27 21:31       ` Lee Revell
  2007-04-27 21:55         ` Alan Cox
  1 sibling, 1 reply; 11+ messages in thread
From: Lee Revell @ 2007-04-27 21:31 UTC (permalink / raw)
  To: Daniel Hazelton
  Cc: Marat Buharov, linux-os (Dick Johnson), Parav K Pandit, linux-kernel

On 4/27/07, Daniel Hazelton <dhazelton@enter.net> wrote:
> Most companies require that *ANY* e-mail sent by employees while at work
> contain disclaimers like those. Some of them even have their mail servers
> *automatically* attach those footers.

These employees should be using gmail (over https) rather than
clogging thousands of people's inboxes with garbage spewed from the
legal dept.

Lee

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: assembly code in the loadable kernel module
  2007-04-27 21:31       ` Lee Revell
@ 2007-04-27 21:55         ` Alan Cox
  0 siblings, 0 replies; 11+ messages in thread
From: Alan Cox @ 2007-04-27 21:55 UTC (permalink / raw)
  To: Lee Revell
  Cc: Daniel Hazelton, Marat Buharov, linux-os (Dick Johnson),
	Parav K Pandit, linux-kernel

> These employees should be using gmail (over https) rather than
> clogging thousands of people's inboxes with garbage spewed from the
> legal dept.

Its much more fun to write back to those people and inform them that
their terms are not valid as a contract can only be entered by joint
agreement and that by continuing to send email to you they clearly
understand this.

Lawyers cost a lot per hour so if they are being a nuisance keep them
employed ;)

Alan

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: assembly code in the loadable kernel module
  2007-04-27 21:06       ` linux-os (Dick Johnson)
@ 2007-05-01 13:08         ` Valdis.Kletnieks
  0 siblings, 0 replies; 11+ messages in thread
From: Valdis.Kletnieks @ 2007-05-01 13:08 UTC (permalink / raw)
  To: linux-os (Dick Johnson)
  Cc: Daniel Hazelton, Marat Buharov, Parav K Pandit, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 735 bytes --]

On Fri, 27 Apr 2007 17:06:48 EDT, "linux-os (Dick Johnson)" said:

>         if(strchr(buf, 'Z'-64) || strchr(buf, 'D'-64))

This probably isn't UTF-8 safe... :)

> Anything after ^D or ^Z doesn't get copied to the list. Something like
> this needs to be done because it's gonna get a whole lot worse because
> all the 'IT' people read the same rags -- so they think that "naked"
> email fails the "due diligence" test. Honest, I'm not making that up!

And here I thought blindly slapping that disclaimer on *everything*, whether
or not it actually called for it, failed "due diligence".  Ain't much diligence,
due or otherwise, in evidence when a "This contains confidential" sticker
gets posted to a worldwide public mailing list...

[-- Attachment #2: Type: application/pgp-signature, Size: 226 bytes --]

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2007-05-01 13:10 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-04-27  8:45 assembly code in the loadable kernel module Parav K Pandit
2007-04-27  9:40 ` Jan Engelhardt
2007-04-27 10:59 ` Sam Ravnborg
2007-04-27 11:27 ` linux-os (Dick Johnson)
2007-04-27 11:57   ` Marat Buharov
2007-04-27 12:11     ` Robert P. J. Day
2007-04-27 16:12     ` Daniel Hazelton
2007-04-27 21:06       ` linux-os (Dick Johnson)
2007-05-01 13:08         ` Valdis.Kletnieks
2007-04-27 21:31       ` Lee Revell
2007-04-27 21:55         ` Alan Cox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).