Giulio Mazzoleni | 4 Jul 2011 16:42
Favicon

Re: [microblaze-linux] LLTEMAC DUAL CHANNEL

After having split the two ll_temac channels in two distinct ll_temac
ips both of the phys are being recongnized (and irqs correctly
assigned).

I finally managed to make the ll_temac driver work in u-boot, at least
for me, in petalinux-v0.40-final.

I just copied some relevant functions (send/recv/init) from the git
version and forced a link=1 in xps_ll_temac_phy_ctrl function.

I am attaching the modified driver and a diff toward the v0.40-final
version.

Hopefully it will be of help to somebody else who, like me, is not that
smart in such things and will save a bit of time.

I could succesfully test it on the sp605 evaluation board, too.

Best regards,
Giulio

On Fri, 2011-06-24 at 15:14 +0200, Giulio Mazzoleni wrote:
> Dear microblaze uclinux users.
> I would like to ask you one more question.
> 
> I am currenlty using a double ethernet interface.
> I had to use two different kind of drivers (ethernetlite + lltemac) to
> be able to use both of them at the same time. I am still not sure about
> the problem that would prevent me to do so when using ethernetlite for
> both of them.
(Continue reading)

Giulio Mazzoleni | 4 Jul 2011 17:08
Favicon

[microblaze-linux] DEBUG MULTITHREAD APP

Dear microblaze uclinux mailing list users,
I would like to ask you some advices, since this neverending problem is
cursing me..

I have written a multi thread application and I am running it on a
microblaze w/out MMU.

It happens that from time to time the app crashes and goes back to the
prompt with no particular error.
Other times it crashes the kernel.

I would greatly accept any suggestion you could give me on how to threat
the issue.

At the moment I have done the following things to debug the problem:
- putting some printf in the code
- monitoring thread liveness with a sort of sw watchdog and restarting
them if blocked (it is not happening)
- putting canaries in functions to watch for buffer overflows

And the following to workaround it:
- calling the app in a while 1 sh script to restart it if crashed
- using an hw watchdog to restart the system if hung

I was willing to try to debug via gdbserver, but I am encountering some
problems. For example when I connect to the remote gdb I cannot read the
plb bus (gpio) nor the external ram.
And when running the app it seems to stop very soon.

I am compiling with "microblaze-uclinux-gcc -g -O0"
(Continue reading)

Giulio Mazzoleni | 4 Jul 2011 17:11
Favicon

Re: [microblaze-linux] LLTEMAC DUAL CHANNEL

Can the exceptions enabled or disabled in the microblaze result in any
different behaviour in a ganeric program execution?
I am attaching the relevant mb mhs instantiation.
Thanks.
Giulio

On Mon, 2011-07-04 at 16:42 +0200, Giulio Mazzoleni wrote:
> After having split the two ll_temac channels in two distinct ll_temac
> ips both of the phys are being recongnized (and irqs correctly
> assigned).
> 
> I finally managed to make the ll_temac driver work in u-boot, at least
> for me, in petalinux-v0.40-final.
> 
> I just copied some relevant functions (send/recv/init) from the git
> version and forced a link=1 in xps_ll_temac_phy_ctrl function.
> 
> I am attaching the modified driver and a diff toward the v0.40-final
> version.
> 
> Hopefully it will be of help to somebody else who, like me, is not that
> smart in such things and will save a bit of time.
> 
> I could succesfully test it on the sp605 evaluation board, too.
> 
> Best regards,
> Giulio
> 
> 
> On Fri, 2011-06-24 at 15:14 +0200, Giulio Mazzoleni wrote:
(Continue reading)

Michal Simek | 5 Jul 2011 13:33
Picon

Re: [microblaze-linux] [PATCH] uio_pdrv_genirq: extensive interrupt search

Hi Stephan,

Stephan Linz wrote:
> In some circumstances, especially in a complex OF environment,
> the interrupt will not present as second resource entry (hard
> coded as &pdev->resource[1]). We need a more precise lookup
> algorithm to find the first valid interrupt entry.
> 
> Signed-off-by: Stephan Linz <linz@...>

I am not sure what your patch solved. I have sent to LKML uio patch which add 
support for OF to UIO. Here is the link https://lkml.org/lkml/2011/5/5/18

There is used platform_get_irq function to find out IRQ.

Is it what you wanted to solved by your patch?

Anyway this is UIO patch not Microblaze specific that's why it is better to send 
it to appropriate mailing list and CC UIO maintainer.

Best regards,
Michal

--

-- 
Michal Simek, Ing. (M.Eng)
w: www.monstr.eu p: +42-0-721842854
Maintainer of Linux kernel 2.6 Microblaze Linux - http://www.monstr.eu/fdt/
Microblaze U-BOOT custodian
_______________________________________________
microblaze-linux mailing list
(Continue reading)

Steven J. Magnani | 5 Jul 2011 13:54

Re: [microblaze-linux] LLTEMAC DUAL CHANNEL

Hi Giulio,

On Mon, 2011-07-04 at 17:11 +0200, Giulio Mazzoleni wrote:
> Can the exceptions enabled or disabled in the microblaze result in any
> different behaviour in a ganeric program execution?

The main one that makes a difference in my experience is unaligned
exceptions. Unless your program goes totally into the weeds I don't
think the others you have enabled would make much difference. And, even
the unaligned exceptions shouldn't make a difference unless you're
dealing with packed data and not compensating for misalignment in
userspace.

Have you checked your program's stack usage to be sure you're not
overflowing it?

> I am attaching the relevant mb mhs instantiation.
> Thanks.
> Giulio

Regards,
------------------------------------------------------------------------
 Steven J. Magnani               "I claim this network for MARS!
 www.digidescorp.com              Earthling, return my space modulator!"

 #include <standard.disclaimer>

_______________________________________________
microblaze-linux mailing list
microblaze-linux@...
(Continue reading)

Michal Simek | 5 Jul 2011 13:48
Picon

Re: [microblaze-linux] [PATCH] uartlite: Make the number of UARTs registered configurable.

Stephan Linz wrote:
> Based on the 8250 code also add a nr_uarts module option to
> override this, up to a maximum of SERIAL_UARTLITE_NR_UARTS
> 
> This should appease people who complain about a proliferation
> of /dev/ttyUL & /sysfs nodes whilst at the same time allowing
> a single kernel image to support the rarer occasions of
> lots of devices.
> 
> So you can avoid related error like:
> [    0.804000] uartlite 84000000.serial: ttyUL4 too large
> [    0.808000] uartlite: probe of 84000000.serial failed with error -22
> 
> Signed-off-by: Stephan Linz <linz@...>
> ---
>  drivers/serial/Kconfig    |   10 ++++++++++
>  drivers/serial/uartlite.c |   20 ++++++++++++++++----
>  2 files changed, 26 insertions(+), 4 deletions(-)

Please use serial mailing list and add Peter Korsgaard to CC. He is responsible 
for this mainline driver.

Best regards,
Michal

--

-- 
Michal Simek, Ing. (M.Eng)
w: www.monstr.eu p: +42-0-721842854
Maintainer of Linux kernel 2.6 Microblaze Linux - http://www.monstr.eu/fdt/
Microblaze U-BOOT custodian
(Continue reading)

Giulio Mazzoleni | 5 Jul 2011 17:28
Favicon

Re: [microblaze-linux] LLTEMAC DUAL CHANNEL

Hi Steven. Thank you.

Yes I am monitoring the software stack by putting some well known data
pattern at the top of the functions and checking it again before
returning.

But maybe there are some more cleaver tricks or libraries to link to,
that can help debugging some misbehaving user program running in a non
MMU system.

And sorry for my mistake in replying (to myself) with the wrong subject
line..

If I'll end up with something usefull I'll give you an update..

On Tue, 2011-07-05 at 06:54 -0500, Steven J. Magnani wrote:
> Hi Giulio,
> 
> On Mon, 2011-07-04 at 17:11 +0200, Giulio Mazzoleni wrote:
> > Can the exceptions enabled or disabled in the microblaze result in any
> > different behaviour in a ganeric program execution?
> 
> The main one that makes a difference in my experience is unaligned
> exceptions. Unless your program goes totally into the weeds I don't
> think the others you have enabled would make much difference. And, even
> the unaligned exceptions shouldn't make a difference unless you're
> dealing with packed data and not compensating for misalignment in
> userspace.
> 
> Have you checked your program's stack usage to be sure you're not
(Continue reading)

Giulio Mazzoleni | 7 Jul 2011 10:28
Favicon

[microblaze-linux] MICROBLAZE APP WITH WEB SERVER

Dear microblaze uclinux mailing list,

I am soon switching from a MMU-less microblaze architecture to a
MMU-enabled one and I would like some suggestions on how to handle a
particular problem about servicing dynamic web pages.

In the embedded world I have been used to control dynamic page creation
directly from a single application (the main application that would run
on the board).

I could do this by using the thttpd web server and passing all the cgi
data from the web server to my application by making use of the cgi-lib
libraries and taking advantage of the intrinsic shared memory space of a
no-MMU system.

I created a cgi-page that would collect every user request. Then it
would store such a request in a struct placed in RAM (as defined by the
cgi-lib library). Then it would notify the main app via a socket
connection telling it the address of the struct and reading back from
the socket the data to be sent to the user.

It worked quite well, but now I won't be able to do such a thing because
of the different memory pools allocated to the various processes in a
MMU system.

Can you suggest me something to try?
- I could pass the whole struct via socket (instead of passing just the
pointer)
- I could allocate a shared memory area
- ...
(Continue reading)

Paulo Ferreira | 7 Jul 2011 11:05

Re: [microblaze-linux] MICROBLAZE APP WITH WEB SERVER


On 2011/07/07, at 09:28, Giulio Mazzoleni wrote:

> Dear microblaze uclinux mailing list,
> 
> I am soon switching from a MMU-less microblaze architecture to a
> MMU-enabled one and I would like some suggestions on how to handle a
> particular problem about servicing dynamic web pages.
> 
> In the embedded world I have been used to control dynamic page creation
> directly from a single application (the main application that would run
> on the board).
> 
> I could do this by using the thttpd web server and passing all the cgi
> data from the web server to my application by making use of the cgi-lib
> libraries and taking advantage of the intrinsic shared memory space of a
> no-MMU system.
> 
> I created a cgi-page that would collect every user request. Then it
> would store such a request in a struct placed in RAM (as defined by the
> cgi-lib library). Then it would notify the main app via a socket
> connection telling it the address of the struct and reading back from
> the socket the data to be sent to the user.
> 
> It worked quite well, but now I won't be able to do such a thing because
> of the different memory pools allocated to the various processes in a
> MMU system.
> 
> Can you suggest me something to try?
> - I could pass the whole struct via socket (instead of passing just the
(Continue reading)

Giulio Mazzoleni | 7 Jul 2011 11:30
Favicon

Re: [microblaze-linux] MICROBLAZE APP WITH WEB SERVER


On Thu, 2011-07-07 at 10:05 +0100, Paulo Ferreira wrote:
> On 2011/07/07, at 09:28, Giulio Mazzoleni wrote:
> 
> > Dear microblaze uclinux mailing list,
> > 
> > I am soon switching from a MMU-less microblaze architecture to a
> > MMU-enabled one and I would like some suggestions on how to handle a
> > particular problem about servicing dynamic web pages.
> > 
> > In the embedded world I have been used to control dynamic page creation
> > directly from a single application (the main application that would run
> > on the board).
> > 
> > I could do this by using the thttpd web server and passing all the cgi
> > data from the web server to my application by making use of the cgi-lib
> > libraries and taking advantage of the intrinsic shared memory space of a
> > no-MMU system.
> > 
> > I created a cgi-page that would collect every user request. Then it
> > would store such a request in a struct placed in RAM (as defined by the
> > cgi-lib library). Then it would notify the main app via a socket
> > connection telling it the address of the struct and reading back from
> > the socket the data to be sent to the user.
> > 
> > It worked quite well, but now I won't be able to do such a thing because
> > of the different memory pools allocated to the various processes in a
> > MMU system.
> > 
> > Can you suggest me something to try?
(Continue reading)


Gmane