Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c8d8170f authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* git://git.linux-xtensa.org/kernel/xtensa-feed:
  Xtensa: use asm-generic/fcntl.h
  [XTENSA] Remove non-rt signal handling
  [XTENSA] Move common sections into bss sections
  [XTENSA] clean-up header files
  [XTENSA] Use generic 64-bit division
  [XTENSA] Remove multi-exported symbols from xtensa_ksyms.c
  [XTENSA] fix sources using deprecated assembler directive
  [XTENSA] Spelling fixes in arch/xtensa
  [XTENSA] fix bit operations in bitops.h
parents 34750bb1 df5e3870
Loading
Loading
Loading
Loading
+1 −0
Original line number Original line Diff line number Diff line
@@ -39,6 +39,7 @@ int main(void)
	DEFINE(PT_LEND, offsetof (struct pt_regs, lend));
	DEFINE(PT_LEND, offsetof (struct pt_regs, lend));
	DEFINE(PT_LCOUNT, offsetof (struct pt_regs, lcount));
	DEFINE(PT_LCOUNT, offsetof (struct pt_regs, lcount));
	DEFINE(PT_SAR, offsetof (struct pt_regs, sar));
	DEFINE(PT_SAR, offsetof (struct pt_regs, sar));
	DEFINE(PT_ICOUNTLEVEL, offsetof (struct pt_regs, icountlevel));
	DEFINE(PT_SYSCALL, offsetof (struct pt_regs, syscall));
	DEFINE(PT_SYSCALL, offsetof (struct pt_regs, syscall));
	DEFINE(PT_AREG, offsetof (struct pt_regs, areg[0]));
	DEFINE(PT_AREG, offsetof (struct pt_regs, areg[0]));
	DEFINE(PT_AREG0, offsetof (struct pt_regs, areg[0]));
	DEFINE(PT_AREG0, offsetof (struct pt_regs, areg[0]));
+14 −22
Original line number Original line Diff line number Diff line
@@ -125,8 +125,9 @@ _user_exception:


	movi	a2, 0
	movi	a2, 0
	rsr	a3, SAR
	rsr	a3, SAR
	wsr	a2, ICOUNTLEVEL
	xsr	a2, ICOUNTLEVEL
	s32i	a3, a1, PT_SAR
	s32i	a3, a1, PT_SAR
	s32i	a2, a1, PT_ICOUNTLEVEL


	/* Rotate ws so that the current windowbase is at bit0. */
	/* Rotate ws so that the current windowbase is at bit0. */
	/* Assume ws = xxwww1yyyy. Rotate ws right, so that a2 = yyyyxxwww1 */
	/* Assume ws = xxwww1yyyy. Rotate ws right, so that a2 = yyyyxxwww1 */
@@ -276,8 +277,9 @@ _kernel_exception:


	movi	a2, 0
	movi	a2, 0
	rsr	a3, SAR
	rsr	a3, SAR
	wsr	a2, ICOUNTLEVEL
	xsr	a2, ICOUNTLEVEL
	s32i	a3, a1, PT_SAR
	s32i	a3, a1, PT_SAR
	s32i	a2, a1, PT_ICOUNTLEVEL


	/* Rotate ws so that the current windowbase is at bit0. */
	/* Rotate ws so that the current windowbase is at bit0. */
	/* Assume ws = xxwww1yyyy. Rotate ws right, so that a2 = yyyyxxwww1 */
	/* Assume ws = xxwww1yyyy. Rotate ws right, so that a2 = yyyyxxwww1 */
@@ -330,14 +332,16 @@ _kernel_exception:


common_exception:
common_exception:


	/* Save EXCVADDR, DEBUGCAUSE, and PC, and clear LCOUNT */
	/* Save some registers, disable loops and clear the syscall flag. */


	rsr	a2, DEBUGCAUSE
	rsr	a2, DEBUGCAUSE
	rsr	a3, EPC_1
	rsr	a3, EPC_1
	s32i	a2, a1, PT_DEBUGCAUSE
	s32i	a2, a1, PT_DEBUGCAUSE
	s32i	a3, a1, PT_PC
	s32i	a3, a1, PT_PC


	movi	a2, -1
	rsr	a3, EXCVADDR
	rsr	a3, EXCVADDR
	s32i	a2, a1, PT_SYSCALL
	movi	a2, 0
	movi	a2, 0
	s32i	a3, a1, PT_EXCVADDR
	s32i	a3, a1, PT_EXCVADDR
	xsr	a2, LCOUNT
	xsr	a2, LCOUNT
@@ -450,27 +454,8 @@ common_exception_return:


	/* Restore the state of the task and return from the exception. */
	/* Restore the state of the task and return from the exception. */



	/* If we are returning from a user exception, and the process
	 * to run next has PT_SINGLESTEP set, we want to setup
	 * ICOUNT and ICOUNTLEVEL to step one instruction.
	 * PT_SINGLESTEP is set by sys_ptrace (ptrace.c)
	 */

4:	/* a2 holds GET_CURRENT(a2,a1)  */
4:	/* a2 holds GET_CURRENT(a2,a1)  */


	l32i	a3, a2, TI_TASK
	l32i	a3, a3, TASK_PTRACE
	bbci.l	a3, PT_SINGLESTEP_BIT, 1f # jump if single-step flag is not set

	movi	a3, -2			# PT_SINGLESTEP flag is set,
	movi	a4, 1			# icountlevel of 1 means it won't
	wsr	a3, ICOUNT		# start counting until after rfe
	wsr	a4, ICOUNTLEVEL		# so setup icount & icountlevel.
	isync

1:

#if XCHAL_EXTRA_SA_SIZE
#if XCHAL_EXTRA_SA_SIZE


	/* For user exceptions, restore the extra state from the user's TCB. */
	/* For user exceptions, restore the extra state from the user's TCB. */
@@ -665,6 +650,13 @@ common_exception_exit:
	wsr	a3, LEND
	wsr	a3, LEND
	wsr	a2, LCOUNT
	wsr	a2, LCOUNT


	/* We control single stepping through the ICOUNTLEVEL register. */

	l32i	a2, a1, PT_ICOUNTLEVEL
	movi	a3, -2
	wsr	a2, ICOUNTLEVEL
	wsr	a3, ICOUNT

	/* Check if it was double exception. */
	/* Check if it was double exception. */


	l32i	a0, a1, PT_DEPC
	l32i	a0, a1, PT_DEPC
+11 −8
Original line number Original line Diff line number Diff line
@@ -19,6 +19,8 @@
#include <asm/page.h>
#include <asm/page.h>
#include <asm/cacheasm.h>
#include <asm/cacheasm.h>


#include <linux/linkage.h>

/*
/*
 * This module contains the entry code for kernel images. It performs the
 * This module contains the entry code for kernel images. It performs the
 * minimal setup needed to call the generic C routines.
 * minimal setup needed to call the generic C routines.
@@ -227,13 +229,14 @@ _startup:
should_never_return:
should_never_return:
	j	should_never_return
	j	should_never_return


	/* Define some common data structures here.  We define them

	 * here in this assembly file due to their unusual alignment
/*
	 * requirements.
 * BSS section
 */
 */
	
	
	.comm   swapper_pg_dir,PAGE_SIZE,PAGE_SIZE
.section ".bss.page_aligned", "w"
	.comm	empty_bad_page_table,PAGE_SIZE,PAGE_SIZE
ENTRY(swapper_pg_dir)
	.comm	empty_bad_page,PAGE_SIZE,PAGE_SIZE
	.fill	PAGE_SIZE, 1, 0
	.comm	empty_zero_page,PAGE_SIZE,PAGE_SIZE
ENTRY(empty_zero_page)
	.fill	PAGE_SIZE, 1, 0
+1 −1
Original line number Original line Diff line number Diff line
@@ -401,7 +401,7 @@ int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma,
 * Also, think for a moment about likes of floppy.c that
 * Also, think for a moment about likes of floppy.c that
 * include architecture specific parts. They may want to redefine ins/outs.
 * include architecture specific parts. They may want to redefine ins/outs.
 *
 *
 * We do not use horroble macroses here because we want to
 * We do not use horrible macros here because we want to
 * advance pointer by sizeof(size).
 * advance pointer by sizeof(size).
 */
 */
void outsb(unsigned long addr, const void *src, unsigned long count) {
void outsb(unsigned long addr, const void *src, unsigned long count) {
+1 −0
Original line number Original line Diff line number Diff line
@@ -41,6 +41,7 @@
#include <asm/platform.h>
#include <asm/platform.h>
#include <asm/page.h>
#include <asm/page.h>
#include <asm/setup.h>
#include <asm/setup.h>
#include <asm/param.h>


#if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_DUMMY_CONSOLE)
#if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_DUMMY_CONSOLE)
struct screen_info screen_info = { 0, 24, 0, 0, 0, 80, 0, 0, 0, 24, 1, 16};
struct screen_info screen_info = { 0, 24, 0, 0, 0, 80, 0, 0, 0, 24, 1, 16};
Loading