[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [microblaze-uclinux] 10 msec number of ticks bug..



John,
The sigaction seems to have problem with optimisation "0". The system
reboots/hangs for signal14 and other signals (if we send signal couple
of times). I used the modified test code send by bret sometime back.
This is with the latest IRQ patch you posted.
BTW, this works ok for optimisation 1 and 2 and s.

I have attached the code and the makefile i used to compile. Please
let me know if you can repeat this.

Thanx
- Prasad

On 9/5/06, John Williams <jwilliams@xxxxxxxxxxxxxx> wrote:
Hi Prasad,

Prasad wrote:

> From the priliminary test i did today, the patch that you posted for
> the "stability under heavy load"  seems to be solving my problem.

OK, that's good news.

> John, i also get the following error sometimes. I posted this in
> uclinux-dev and did  google-ing and i didn't get any convincing
> answer/reasons for the occurance.  Most of the message points as a
> harmless problem although i am not sure on this. Do u have any idea on
> this/usual suspects.
> =======================================
> <4>Aug 28 22:53:41 kernel: ksize on unknown page type (index=34)!
> <4>Aug 28 23:00:25 last message repeated 755 time(s)
> <4>Aug 28 23:00:25 kernel: ksize on unknown page type (index=32)!
> <4>Aug 28 23:02:06 last message repeated 188 time(s)
> <4>Aug 28 23:02:06 kernel: ksize on unknown page type (index=34)!
> ================================================

It doesn't look right.  I'd be putting a breakpoint in the ksize() function
where it generates that error, then run the system until it traps.  Look at the
stack and see where it's being called from.

Cheers,

John

___________________________
microblaze-uclinux mailing list
microblaze-uclinux@xxxxxxxxxxxxxx
Project Home Page : http://www.itee.uq.edu.au/~jwilliams/mblaze-uclinux
Mailing List Archive : http://www.itee.uq.edu.au/~listarch/microblaze-uclinux/


#include <sys/types.h>
#include <sys/socket.h>
#include <arpa/inet.h>
#include <signal.h>


void
test_sig_usr1_hdlr(int signal, siginfo_t *info, void *unused)
{
	printf ("in test sig usr1 hdlr\n");
}

int main (int argc, char * argv[] )
{

	int sock;
	struct sockaddr_in myaddr, cliaddr;
	char msgbuf [1000];
	socklen_t clilen;
	int msglen;
	int count;

#if 1
	struct sigaction tstSignalActions;
	sigset_t tstSignals;
#else
	__sighandler_t tstSignalActions;
#endif

    	int err;
    	extern int errno;

#if 1
	sigemptyset(&tstSignals);
	tstSignalActions.sa_mask      = tstSignals;
//	tstSignalActions.sa_flags     = SA_RESTART | SA_SIGINFO;
//	tstSignalActions.sa_flags     = SA_RESTART;
	tstSignalActions.sa_flags     = 0;
	tstSignalActions.sa_sigaction   = test_sig_usr1_hdlr;
//	err = sigaction(SIGUSR1, &tstSignalActions, NULL);
	for (count = 0; count < 32; count++)
		err = sigaction(count, &tstSignalActions, NULL);
#else
	err = signal (SIGUSR1, &tstSignalActions);
#endif


        memset (&myaddr, 0, sizeof (myaddr));
	sock = socket (PF_INET, SOCK_DGRAM, 0);
        myaddr.sin_family = AF_INET;
	myaddr.sin_port = htons (11111);
	myaddr.sin_addr.s_addr = htonl (INADDR_ANY);

	bind (sock, (struct sockaddr *) &myaddr, sizeof (myaddr));

        // blocked on Listening on udp port 11111

	while (1) {
		clilen=sizeof(cliaddr);
		msglen=recvfrom(sock,msgbuf,1000,0, ( struct sockaddr *)  &cliaddr,&clilen);
		printf ("msg received\n");
		continue;
	}
}

Attachment: Makefile
Description: Binary data