Hi Wendy,
I’m testing the code on an ml505 without MMU support (ML505-ll_temac-sgdma-edk101) – I have now updated to the latest SVN version and I am still getting the same results.
I have attached my config files as you asked.
I have also built the latest SVN version with the MMU enabled (ML505-ll_temac-sgdma-MMU-edk101) and have had some very intriguing results when running the same piece of code: The module no longer causes an illegal instruction however the function calls in between the first __init function and the most deeply nested function are skipped??? (I have written another simple example to show this a bit clearer than I am explaining it!!!)
----------------------------------------
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/module.h>
MODULE_AUTHOR("Ian Whitmore");
MODULE_DESCRIPTION("Discovery communications example");
MODULE_LICENSE("Dual BSD/GPL");
static void testa(int i);
static void testb(int i);
static void testc(int i);
static void testd(int i);
void testd(int i)
{
printk("I'm in testd: %d\n", i);
return;
}
void testc(int i)
{
printk("I'm in testc: %d\n", i);
testd(++i);
testd(++i);
}
void testb(int i)
{
printk("I'm in testb: %d\n", i);
testc(++i);
testc(++i);
}
void testa(int i)
{
printk("I'm in testa: %d\n", i);
testb(++i);
testb(++i);
}
void __exit stopGoing(void)
{
printk("I'm in stopGoing\n");
testa(2);
}
int __init startGoing(void)
{
printk("I'm in startGoing\n");
testa(1);
return 0;
}
module_init(startGoing);
module_exit(stopGoing);
----------------------------------------------------
Output:
-----------------------------------------------------
/var/tmp # insmod discovery-module.ko
I'm in startGoing
I'm in testd: 1
/var/tmp #
As you can see from the example testa, testb and testc have all been skipped as i has not been incremented but testd is called?
Although this is different behaviour from my original example(and a completely different platform) I think both could be a symptom of the same problem.
I will also try to replicate the same on a Spartan3A for my own sanity if nothing else!!!!
Thank you for you efforts.
Ian
The information contained in this E-Mail and any subsequent
correspondence is private and is intended solely for the intended
recipient(s). The information in this communication may be
confidential and/or legally privileged. Nothing in this e-mail is
intended to conclude a contract on behalf of QinetiQ or make QinetiQ
subject to any other legally binding commitments, unless the e-mail
contains an express statement to the contrary or incorporates a formal Purchase Order.For those other than the recipient any disclosure, copying,
distribution, or any action taken or omitted to be taken in reliance
on such information is prohibited and may be unlawful.Emails and other electronic communication with QinetiQ may be
monitored and recorded for business purposes including security, audit
and archival purposes. Any response to this email indicates consent
to this.Telephone calls to QinetiQ may be monitored or recorded for quality
control, security and other business purposes.QinetiQ Limited
Registered in England & Wales: Company Number:3796233
Registered office: 85 Buckingham Gate, London SW1E 6PD, United Kingdom
Trading address: Cody Technology Park, Cody Building, Ively Road, Farnborough, Hampshire, GU14 0LX, United Kingdom
http://www.qinetiq.com/home/notices/legal.html