Commit graph

8 commits

Author SHA1 Message Date
Michal Simek 55ae2f3b88 microblaze: Label local function static
Warnings found by sparse:
arch/microblaze/kernel/dma.c:157:5: warning: symbol
'dma_direct_mmap_coherent' was not declared. Should it be static?
arch/microblaze/kernel/kgdb.c:35:14: warning: symbol 'pvr' was not
declared. Should it be static?

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2015-06-08 09:57:08 +02:00
Michal Simek e76fdb3248 microblaze: Use unsigned type for "for" loop because of comparison-kgdb.c
This patch removes warnings reported by W=1:
arch/microblaze/kernel/kgdb.c: In function 'pt_regs_to_gdb_regs':
arch/microblaze/kernel/kgdb.c:43:16: warning: comparison between signed
and unsigned integer expressions [-Wsign-compare]
arch/microblaze/kernel/kgdb.c:51:16: warning: comparison between signed
and unsigned integer expressions [-Wsign-compare]
arch/microblaze/kernel/kgdb.c: In function 'gdb_regs_to_pt_regs':
arch/microblaze/kernel/kgdb.c:77:16: warning: comparison between signed
and unsigned integer expressions [-Wsign-compare]
arch/microblaze/kernel/kgdb.c: In function
'sleeping_thread_to_gdb_regs':
arch/microblaze/kernel/kgdb.c:99:16: warning: comparison between signed
and unsigned integer expressions [-Wsign-compare]
arch/microblaze/kernel/kgdb.c:103:16: warning: comparison between signed
and unsigned integer expressions [-Wsign-compare]

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2015-01-05 12:36:45 +01:00
Michal Simek f396a4d231 microblaze: Declare microblaze_kgdb_break in header
This patch removes the warning:
arch/microblaze/kernel/kgdb.c:81:6: warning: no previous prototype for
'microblaze_kgdb_break' [-Wmissing-prototypes]

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2015-01-05 12:36:42 +01:00
Graeme Smecher 218a12f1f4 microblaze: Don't mark arch_kgdb_ops as const.
Other architectures don't do it, and it conflicts with the extern'd definition
in include/linux/kgdb.h.

The patch fails checkpatch but it reflects current
functions declaration and solved compilation error.

Signed-off-by: Graeme Smecher <gsmecher@threespeedlogic.com>
CC: Michal Simek <monstr@monstr.eu>
CC: linux-kernel@vger.kernel.org
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
2013-06-26 11:36:55 +02:00
Michal Simek 6bd55f0bba microblaze: Fix coding style issues
Fix coding style issues reported by checkpatch.pl.

Signed-off-by: Michal Simek <monstr@monstr.eu>
2013-02-12 11:24:45 +01:00
Michal Simek e4f2909227 microblaze: KGDB little endian support
Just need to use little-endian opcode for brki r16, 0x18

Signed-off-by: Michal Simek <monstr@monstr.eu>
CC: Jason Wessel <jason.wessel@windriver.com>
2010-10-21 15:51:58 +10:00
Michal Simek f859f0a235 microblaze: kgdb: Remove unused variable and fix return value
I forget to remove unused variable from kgdb_arch_handle_exception.
Fix return value in microblaze_kgdb_break function.

Error log:
arch/microblaze/kernel/kgdb.c: In function 'microblaze_kgdb_break':
arch/microblaze/kernel/kgdb.c:83: warning: 'return' with a value, in function returning void
arch/microblaze/kernel/kgdb.c: In function 'kgdb_arch_handle_exception':
arch/microblaze/kernel/kgdb.c:119: warning: unused variable 'cpu'

Signed-off-by: Michal Simek <monstr@monstr.eu>
2010-10-21 15:51:19 +10:00
Michal Simek 2d5973cb5a microblaze: Add KGDB support
Kgdb uses brki r16, 0x18 instruction to call
low level _debug_exception function which save
current state to pt_regs and call microblaze_kgdb_break
function. _debug_exception should be called only from
the kernel space. User space calling is not supported
because user application debugging uses different handling.

pt_regs_to_gdb_regs loads additional special registers
which can't be changed

 * Enable KGDB in Kconfig
 * Remove ancient not-tested KGDB support
 * Remove ancient _debug_exception code from entry.S

Only MMU KGDB support is supported.

Signed-off-by: Michal Simek <monstr@monstr.eu>
CC: Jason Wessel <jason.wessel@windriver.com>
CC: John Williams <john.williams@petalogix.com>
CC: Edgar E. Iglesias <edgar.iglesias@petalogix.com>
CC: linux-kernel@vger.kernel.org
Acked-by: Jason Wessel <jason.wessel@windriver.com>
2010-08-04 10:45:17 +02:00