linux-stable/arch/m68k/emu
Geert Uytterhoeven e8184e10f8 m68k/atari: ARAnyM - Fix NatFeat module support
As pointed out by Andreas Schwab, pointers passed to ARAnyM NatFeat calls
should be physical addresses, not virtual addresses.

Fortunately on Atari, physical and virtual kernel addresses are the same,
as long as normal kernel memory is concerned, so this usually worked fine
without conversion.

But for modules, pointers to literal strings are located in vmalloc()ed
memory. Depending on the version of ARAnyM, this causes the nf_get_id()
call to just fail, or worse, crash ARAnyM itself with e.g.

    Gotcha! Illegal memory access. Atari PC = $968c

This is a big issue for distro kernels, who want to have all drivers as
loadable modules in an initrd.

Add a wrapper for nf_get_id() that copies the literal to the stack to
work around this issue.

Reported-by: Thorsten Glaser <tg@debian.org>
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: stable@vger.kernel.org
2013-08-14 11:46:30 +02:00
..
Makefile m68k/atari: ARAnyM - Add support for network access 2011-03-16 19:10:41 +01:00
natfeat.c m68k/atari: ARAnyM - Fix NatFeat module support 2013-08-14 11:46:30 +02:00
nfblock.c block: remove support for bio remapping from ->make_request 2011-09-12 12:12:01 +02:00
nfcon.c TTY: call tty_port_destroy in the rest of drivers 2012-11-15 17:20:58 -08:00
nfeth.c ARCH: drivers remove __dev* attributes. 2013-01-03 15:57:13 -08:00