mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Waldemar Brodkorb <wbx@openadk.org>
To: Waldemar Brodkorb <wbx@openadk.org>
Cc: linux-kernel@vger.kernel.org,
	Denys Vlasenko <vda.linux@googlemail.com>,
	Thomas Petazzoni <thomas.petazzoni@free-electrons.com>,
	Gustavo Zacarias <gustavo@zacarias.com.ar>,
	Greg Ungerer <gerg@uclinux.org>
Subject: Re: qemu m68k/mcf5208: problem with signal handler
Date: Mon, 9 May 2016 10:58:15 +0200	[thread overview]
Message-ID: <20160509085815.GB13502@waldemar-brodkorb.de> (raw)
In-Reply-To: <20160509063902.GL26720@waldemar-brodkorb.de>

Hi,

forgot to add Greg in CC.
And sorry for the whitespace fuckup in the example code.

Waldemar Brodkorb wrote,

> Dear kernel hackers,
> 
> I have a problem with the signal handling under qemu-system-m68k
> emulating coldfire mcf5208 evalboard. Following example code
> provided by Busybox maintainer Denys Vlasenko
> shows the problem when running on qemu:

[ .. ]

> You can generate a bootable image with latest buildroot, which shows the issue:
> $ git clone git://git.buildroot.net/buildroot
> $ cd buildroot; make qemu_m68k_mcf5208_defconfig; make
> $ qemu-system-m68k -M mcf5208evb -cpu m5208 -kernel output/images/vmlinux -nographic
> 
> Every command forked from busybox hush shell will lead into a segmentation fault.
> 
> I added following printk to start investigating the problem:
> diff -Nur linux-4.5.3.orig/arch/m68k/kernel/signal.c linux-4.5.3/arch/m68k/kernel/signal.c
> --- linux-4.5.3.orig/arch/m68k/kernel/signal.c	2016-05-04 23:50:38.000000000 +0200
> +++ linux-4.5.3/arch/m68k/kernel/signal.c	2016-05-09 04:24:53.885199544 +0200
> @@ -595,6 +595,7 @@
>  			       void __user *fp)
>  {
>  	int fsize = frame_extra_sizes(formatvec >> 12);
> +	printk("avoid broken signal handler...\n");
>  	if (fsize < 0) {
>  		/*
>  		 * user process trying to return with weird frame format
> 
> But now the problem disappeared. :/
> 
> What do you think? Is it a Kernel bug or a C library problem?
> 
> Busybox hush otherwise works fine for other noMMU targets as stm32
> evalboard with cortex-m4. It also works in Qemu M68k emulating Q800
> full MMU system.
> 
> Thanks for any ideas,
>  Waldemar
> 
> http://lists.busybox.net/pipermail/busybox/2014-September/081659.html
> 

  reply	other threads:[~2016-05-09  8:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-09  6:39 Waldemar Brodkorb
2016-05-09  8:58 ` Waldemar Brodkorb [this message]
2016-05-09 13:57   ` Greg Ungerer
2016-05-09 16:29     ` Waldemar Brodkorb

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160509085815.GB13502@waldemar-brodkorb.de \
    --to=wbx@openadk.org \
    --cc=gerg@uclinux.org \
    --cc=gustavo@zacarias.com.ar \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mail@waldemar-brodkorb.de \
    --cc=thomas.petazzoni@free-electrons.com \
    --cc=vda.linux@googlemail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®