mirror of
https://github.com/torvalds/linux.git
synced 2026-06-09 07:03:37 +02:00
Merge branch 'develop' of xjh@10.10.10.29:/home/rockchip/kernel into develop
This commit is contained in:
commit
bd73d52914
|
|
@ -176,7 +176,6 @@ read the file /proc/PID/status:
|
|||
CapBnd: ffffffffffffffff
|
||||
voluntary_ctxt_switches: 0
|
||||
nonvoluntary_ctxt_switches: 1
|
||||
Stack usage: 12 kB
|
||||
|
||||
This shows you nearly the same information you would get if you viewed it with
|
||||
the ps command. In fact, ps uses the proc file system to obtain its
|
||||
|
|
@ -230,7 +229,6 @@ Table 1-2: Contents of the statm files (as of 2.6.30-rc7)
|
|||
Mems_allowed_list Same as previous, but in "list format"
|
||||
voluntary_ctxt_switches number of voluntary context switches
|
||||
nonvoluntary_ctxt_switches number of non voluntary context switches
|
||||
Stack usage: stack usage high water mark (round up to page size)
|
||||
..............................................................................
|
||||
|
||||
Table 1-3: Contents of the statm files (as of 2.6.8-rc3)
|
||||
|
|
@ -309,7 +307,7 @@ address perms offset dev inode pathname
|
|||
08049000-0804a000 rw-p 00001000 03:00 8312 /opt/test
|
||||
0804a000-0806b000 rw-p 00000000 00:00 0 [heap]
|
||||
a7cb1000-a7cb2000 ---p 00000000 00:00 0
|
||||
a7cb2000-a7eb2000 rw-p 00000000 00:00 0 [threadstack:001ff4b4]
|
||||
a7cb2000-a7eb2000 rw-p 00000000 00:00 0
|
||||
a7eb2000-a7eb3000 ---p 00000000 00:00 0
|
||||
a7eb3000-a7ed5000 rw-p 00000000 00:00 0
|
||||
a7ed5000-a8008000 r-xp 00000000 03:00 4222 /lib/libc.so.6
|
||||
|
|
@ -345,7 +343,6 @@ is not associated with a file:
|
|||
[stack] = the stack of the main process
|
||||
[vdso] = the "virtual dynamic shared object",
|
||||
the kernel system call handler
|
||||
[threadstack:xxxxxxxx] = the stack of the thread, xxxxxxxx is the stack size
|
||||
|
||||
or if empty, the mapping is anonymous.
|
||||
|
||||
|
|
|
|||
|
|
@ -82,11 +82,13 @@ tmpfs has a mount option to set the NUMA memory allocation policy for
|
|||
all files in that instance (if CONFIG_NUMA is enabled) - which can be
|
||||
adjusted on the fly via 'mount -o remount ...'
|
||||
|
||||
mpol=default prefers to allocate memory from the local node
|
||||
mpol=default use the process allocation policy
|
||||
(see set_mempolicy(2))
|
||||
mpol=prefer:Node prefers to allocate memory from the given Node
|
||||
mpol=bind:NodeList allocates memory only from nodes in NodeList
|
||||
mpol=interleave prefers to allocate from each node in turn
|
||||
mpol=interleave:NodeList allocates from each node of NodeList in turn
|
||||
mpol=local prefers to allocate memory from the local node
|
||||
|
||||
NodeList format is a comma-separated list of decimal numbers and ranges,
|
||||
a range being two hyphen-separated decimal numbers, the smallest and
|
||||
|
|
@ -134,3 +136,5 @@ Author:
|
|||
Christoph Rohland <cr@sap.com>, 1.12.01
|
||||
Updated:
|
||||
Hugh Dickins, 4 June 2007
|
||||
Updated:
|
||||
KOSAKI Motohiro, 16 Mar 2010
|
||||
|
|
|
|||
|
|
@ -72,9 +72,7 @@ in6_min_alarm 5v output undervoltage alarm
|
|||
in7_min_alarm 3v output undervoltage alarm
|
||||
in8_min_alarm Vee (-12v) output undervoltage alarm
|
||||
|
||||
in9_input GPIO #1 voltage data
|
||||
in10_input GPIO #2 voltage data
|
||||
in11_input GPIO #3 voltage data
|
||||
in9_input GPIO voltage data
|
||||
|
||||
power1_input 12v power usage (mW)
|
||||
power2_input 5v power usage (mW)
|
||||
|
|
|
|||
|
|
@ -15,7 +15,8 @@ Supported adapters:
|
|||
* Intel 82801I (ICH9)
|
||||
* Intel EP80579 (Tolapai)
|
||||
* Intel 82801JI (ICH10)
|
||||
* Intel PCH
|
||||
* Intel 3400/5 Series (PCH)
|
||||
* Intel Cougar Point (PCH)
|
||||
Datasheets: Publicly available at the Intel website
|
||||
|
||||
Authors:
|
||||
|
|
|
|||
|
|
@ -241,7 +241,7 @@ and is between 256 and 4096 characters. It is defined in the file
|
|||
|
||||
acpi_sleep= [HW,ACPI] Sleep options
|
||||
Format: { s3_bios, s3_mode, s3_beep, s4_nohwsig,
|
||||
old_ordering, s4_nonvs }
|
||||
old_ordering, s4_nonvs, sci_force_enable }
|
||||
See Documentation/power/video.txt for information on
|
||||
s3_bios and s3_mode.
|
||||
s3_beep is for debugging; it makes the PC's speaker beep
|
||||
|
|
@ -254,6 +254,9 @@ and is between 256 and 4096 characters. It is defined in the file
|
|||
of _PTS is used by default).
|
||||
s4_nonvs prevents the kernel from saving/restoring the
|
||||
ACPI NVS memory during hibernation.
|
||||
sci_force_enable causes the kernel to set SCI_EN directly
|
||||
on resume from S1/S3 (which is against the ACPI spec,
|
||||
but some broken systems don't work without it).
|
||||
|
||||
acpi_use_timer_override [HW,ACPI]
|
||||
Use timer override. For some broken Nvidia NF5 boards
|
||||
|
|
@ -2668,6 +2671,13 @@ and is between 256 and 4096 characters. It is defined in the file
|
|||
medium is write-protected).
|
||||
Example: quirks=0419:aaf5:rl,0421:0433:rc
|
||||
|
||||
userpte=
|
||||
[X86] Flags controlling user PTE allocations.
|
||||
|
||||
nohigh = do not allocate PTE pages in
|
||||
HIGHMEM regardless of setting
|
||||
of CONFIG_HIGHPTE.
|
||||
|
||||
vdso= [X86,SH]
|
||||
vdso=2: enable compat VDSO (default with COMPAT_VDSO)
|
||||
vdso=1: enable VDSO (default)
|
||||
|
|
|
|||
|
|
@ -460,6 +460,8 @@ event code Key Notes
|
|||
For Lenovo ThinkPads with a new
|
||||
BIOS, it has to be handled either
|
||||
by the ACPI OSI, or by userspace.
|
||||
The driver does the right thing,
|
||||
never mess with this.
|
||||
0x1011 0x10 FN+END Brightness down. See brightness
|
||||
up for details.
|
||||
|
||||
|
|
@ -582,46 +584,15 @@ with hotkey_report_mode.
|
|||
|
||||
Brightness hotkey notes:
|
||||
|
||||
These are the current sane choices for brightness key mapping in
|
||||
thinkpad-acpi:
|
||||
Don't mess with the brightness hotkeys in a Thinkpad. If you want
|
||||
notifications for OSD, use the sysfs backlight class event support.
|
||||
|
||||
For IBM and Lenovo models *without* ACPI backlight control (the ones on
|
||||
which thinkpad-acpi will autoload its backlight interface by default,
|
||||
and on which ACPI video does not export a backlight interface):
|
||||
|
||||
1. Don't enable or map the brightness hotkeys in thinkpad-acpi, as
|
||||
these older firmware versions unfortunately won't respect the hotkey
|
||||
mask for brightness keys anyway, and always reacts to them. This
|
||||
usually work fine, unless X.org drivers are doing something to block
|
||||
the BIOS. In that case, use (3) below. This is the default mode of
|
||||
operation.
|
||||
|
||||
2. Enable the hotkeys, but map them to something else that is NOT
|
||||
KEY_BRIGHTNESS_UP/DOWN or any other keycode that would cause
|
||||
userspace to try to change the backlight level, and use that as an
|
||||
on-screen-display hint.
|
||||
|
||||
3. IF AND ONLY IF X.org drivers find a way to block the firmware from
|
||||
automatically changing the brightness, enable the hotkeys and map
|
||||
them to KEY_BRIGHTNESS_UP and KEY_BRIGHTNESS_DOWN, and feed that to
|
||||
something that calls xbacklight. thinkpad-acpi will not be able to
|
||||
change brightness in that case either, so you should disable its
|
||||
backlight interface.
|
||||
|
||||
For Lenovo models *with* ACPI backlight control:
|
||||
|
||||
1. Load up ACPI video and use that. ACPI video will report ACPI
|
||||
events for brightness change keys. Do not mess with thinkpad-acpi
|
||||
defaults in this case. thinkpad-acpi should not have anything to do
|
||||
with backlight events in a scenario where ACPI video is loaded:
|
||||
brightness hotkeys must be disabled, and the backlight interface is
|
||||
to be kept disabled as well. This is the default mode of operation.
|
||||
|
||||
2. Do *NOT* load up ACPI video, enable the hotkeys in thinkpad-acpi,
|
||||
and map them to KEY_BRIGHTNESS_UP and KEY_BRIGHTNESS_DOWN. Process
|
||||
these keys on userspace somehow (e.g. by calling xbacklight).
|
||||
The driver will do this automatically if it detects that ACPI video
|
||||
has been disabled.
|
||||
The driver will issue KEY_BRIGHTNESS_UP and KEY_BRIGHTNESS_DOWN events
|
||||
automatically for the cases were userspace has to do something to
|
||||
implement brightness changes. When you override these events, you will
|
||||
either fail to handle properly the ThinkPads that require explicit
|
||||
action to change backlight brightness, or the ThinkPads that require
|
||||
that no action be taken to work properly.
|
||||
|
||||
|
||||
Bluetooth
|
||||
|
|
@ -679,6 +650,10 @@ LCD, CRT or DVI (if available). The following commands are available:
|
|||
echo expand_toggle > /proc/acpi/ibm/video
|
||||
echo video_switch > /proc/acpi/ibm/video
|
||||
|
||||
NOTE: Access to this feature is restricted to processes owning the
|
||||
CAP_SYS_ADMIN capability for safety reasons, as it can interact badly
|
||||
enough with some versions of X.org to crash it.
|
||||
|
||||
Each video output device can be enabled or disabled individually.
|
||||
Reading /proc/acpi/ibm/video shows the status of each device.
|
||||
|
||||
|
|
@ -1465,3 +1440,5 @@ Sysfs interface changelog:
|
|||
and it is always able to disable hot keys. Very old
|
||||
thinkpads are properly supported. hotkey_bios_mask
|
||||
is deprecated and marked for removal.
|
||||
|
||||
0x020600: Marker for backlight change event support.
|
||||
|
|
|
|||
|
|
@ -48,11 +48,11 @@ for LILO parameters for doing this:
|
|||
This configures the first found 3c509 card for IRQ 10, base I/O 0x310, and
|
||||
transceiver type 3 (10base2). The flag "0x3c509" must be set to avoid conflicts
|
||||
with other card types when overriding the I/O address. When the driver is
|
||||
loaded as a module, only the IRQ and transceiver setting may be overridden.
|
||||
For example, setting two cards to 10base2/IRQ10 and AUI/IRQ11 is done by using
|
||||
the xcvr and irq module options:
|
||||
loaded as a module, only the IRQ may be overridden. For example,
|
||||
setting two cards to IRQ10 and IRQ11 is done by using the irq module
|
||||
option:
|
||||
|
||||
options 3c509 xcvr=3,1 irq=10,11
|
||||
options 3c509 irq=10,11
|
||||
|
||||
|
||||
(2) Full-duplex mode
|
||||
|
|
@ -77,6 +77,8 @@ operation.
|
|||
itself full-duplex capable. This is almost certainly one of two things: a full-
|
||||
duplex-capable Ethernet switch (*not* a hub), or a full-duplex-capable NIC on
|
||||
another system that's connected directly to the 3c509B via a crossover cable.
|
||||
|
||||
Full-duplex mode can be enabled using 'ethtool'.
|
||||
|
||||
/////Extremely important caution concerning full-duplex mode/////
|
||||
Understand that the 3c509B's hardware's full-duplex support is much more
|
||||
|
|
@ -113,6 +115,8 @@ This insured that merely upgrading the driver from an earlier version would
|
|||
never automatically enable full-duplex mode in an existing installation;
|
||||
it must always be explicitly enabled via one of these code in order to be
|
||||
activated.
|
||||
|
||||
The transceiver type can be changed using 'ethtool'.
|
||||
|
||||
|
||||
(4a) Interpretation of error messages and common problems
|
||||
|
|
|
|||
|
|
@ -1974,6 +1974,12 @@ W: http://acpi4asus.sf.net
|
|||
S: Maintained
|
||||
F: drivers/platform/x86/eeepc-laptop.c
|
||||
|
||||
EFIFB FRAMEBUFFER DRIVER
|
||||
L: linux-fbdev@vger.kernel.org
|
||||
M: Peter Jones <pjones@redhat.com>
|
||||
S: Maintained
|
||||
F: drivers/video/efifb.c
|
||||
|
||||
EFS FILESYSTEM
|
||||
W: http://aeschi.ch.eu.org/efs/
|
||||
S: Orphan
|
||||
|
|
|
|||
6
Makefile
6
Makefile
|
|
@ -1,7 +1,7 @@
|
|||
VERSION = 2
|
||||
PATCHLEVEL = 6
|
||||
SUBLEVEL = 32
|
||||
EXTRAVERSION = .9
|
||||
EXTRAVERSION = .27
|
||||
NAME = Man-Eating Seals of Antiquity
|
||||
|
||||
# *DOCUMENTATION*
|
||||
|
|
@ -1596,3 +1596,7 @@ FORCE:
|
|||
# Declare the contents of the .PHONY variable as phony. We keep that
|
||||
# information in a variable so we can use it in if_changed and friends.
|
||||
.PHONY: $(PHONY)
|
||||
|
||||
|
||||
%.o: %.uu prepare scripts FORCE
|
||||
$(Q)$(MAKE) $(build)=$(build-dir) $(target-dir)$(notdir $@)
|
||||
|
|
|
|||
|
|
@ -6,8 +6,6 @@ config OPROFILE
|
|||
tristate "OProfile system profiling (EXPERIMENTAL)"
|
||||
depends on PROFILING
|
||||
depends on HAVE_OPROFILE
|
||||
depends on TRACING_SUPPORT
|
||||
select TRACING
|
||||
select RING_BUFFER
|
||||
select RING_BUFFER_ALLOW_SWAP
|
||||
help
|
||||
|
|
|
|||
|
|
@ -109,7 +109,7 @@ marvel_print_err_cyc(u64 err_cyc)
|
|||
#define IO7__ERR_CYC__CYCLE__M (0x7)
|
||||
|
||||
printk("%s Packet In Error: %s\n"
|
||||
"%s Error in %s, cycle %ld%s%s\n",
|
||||
"%s Error in %s, cycle %lld%s%s\n",
|
||||
err_print_prefix,
|
||||
packet_desc[EXTRACT(err_cyc, IO7__ERR_CYC__PACKET)],
|
||||
err_print_prefix,
|
||||
|
|
@ -313,7 +313,7 @@ marvel_print_po7_ugbge_sym(u64 ugbge_sym)
|
|||
}
|
||||
|
||||
printk("%s Up Hose Garbage Symptom:\n"
|
||||
"%s Source Port: %ld - Dest PID: %ld - OpCode: %s\n",
|
||||
"%s Source Port: %lld - Dest PID: %lld - OpCode: %s\n",
|
||||
err_print_prefix,
|
||||
err_print_prefix,
|
||||
EXTRACT(ugbge_sym, IO7__PO7_UGBGE_SYM__UPH_SRC_PORT),
|
||||
|
|
@ -552,7 +552,7 @@ marvel_print_pox_spl_cmplt(u64 spl_cmplt)
|
|||
#define IO7__POX_SPLCMPLT__REM_BYTE_COUNT__M (0xfff)
|
||||
|
||||
printk("%s Split Completion Error:\n"
|
||||
"%s Source (Bus:Dev:Func): %ld:%ld:%ld\n",
|
||||
"%s Source (Bus:Dev:Func): %lld:%lld:%lld\n",
|
||||
err_print_prefix,
|
||||
err_print_prefix,
|
||||
EXTRACT(spl_cmplt, IO7__POX_SPLCMPLT__SOURCE_BUS),
|
||||
|
|
|
|||
|
|
@ -722,10 +722,11 @@ config ARCH_RK29
|
|||
select CPU_V7
|
||||
select HAVE_CLK
|
||||
select COMMON_CLKDEV
|
||||
select ARCH_HAS_CPUFREQ
|
||||
select GENERIC_TIME
|
||||
select GENERIC_CLOCKEVENTS
|
||||
select ARCH_REQUIRE_GPIOLIB
|
||||
select ARM_GIC
|
||||
select ARM_GIC
|
||||
help
|
||||
Support for Rockchip RK29 soc.
|
||||
|
||||
|
|
@ -918,6 +919,18 @@ config ARM_ERRATA_460075
|
|||
ACTLR register. Note that setting specific bits in the ACTLR register
|
||||
may not be available in non-secure mode.
|
||||
|
||||
config ARM_ERRATA_720789
|
||||
bool "ARM errata: TLBIASIDIS and TLBIMVAIS operations can broadcast a faulty ASID"
|
||||
depends on CPU_V7 && SMP
|
||||
help
|
||||
This option enables the workaround for the 720789 Cortex-A9 (prior to
|
||||
r2p0) erratum. A faulty ASID can be sent to the other CPUs for the
|
||||
broadcasted CP15 TLB maintenance operations TLBIASIDIS and TLBIMVAIS.
|
||||
As a consequence of this erratum, some TLB entries which should be
|
||||
invalidated are not, resulting in an incoherency in the system page
|
||||
tables. The workaround changes the TLB flushing routines to invalidate
|
||||
entries regardless of the ASID.
|
||||
|
||||
endmenu
|
||||
|
||||
source "arch/arm/common/Kconfig"
|
||||
|
|
|
|||
|
|
@ -162,9 +162,9 @@ not_angel:
|
|||
|
||||
.text
|
||||
adr r0, LC0
|
||||
ARM( ldmia r0, {r1, r2, r3, r4, r5, r6, ip, sp} )
|
||||
THUMB( ldmia r0, {r1, r2, r3, r4, r5, r6, ip} )
|
||||
THUMB( ldr sp, [r0, #28] )
|
||||
ARM( ldmia r0, {r1, r2, r3, r4, r5, r6, r11, ip, sp})
|
||||
THUMB( ldmia r0, {r1, r2, r3, r4, r5, r6, r11, ip} )
|
||||
THUMB( ldr sp, [r0, #32] )
|
||||
subs r0, r0, r1 @ calculate the delta offset
|
||||
|
||||
@ if delta is zero, we are
|
||||
|
|
@ -174,12 +174,13 @@ not_angel:
|
|||
/*
|
||||
* We're running at a different address. We need to fix
|
||||
* up various pointers:
|
||||
* r5 - zImage base address
|
||||
* r6 - GOT start
|
||||
* r5 - zImage base address (_start)
|
||||
* r6 - size of decompressed image
|
||||
* r11 - GOT start
|
||||
* ip - GOT end
|
||||
*/
|
||||
add r5, r5, r0
|
||||
add r6, r6, r0
|
||||
add r11, r11, r0
|
||||
add ip, ip, r0
|
||||
|
||||
#ifndef CONFIG_ZBOOT_ROM
|
||||
|
|
@ -197,10 +198,10 @@ not_angel:
|
|||
/*
|
||||
* Relocate all entries in the GOT table.
|
||||
*/
|
||||
1: ldr r1, [r6, #0] @ relocate entries in the GOT
|
||||
1: ldr r1, [r11, #0] @ relocate entries in the GOT
|
||||
add r1, r1, r0 @ table. This fixes up the
|
||||
str r1, [r6], #4 @ C references.
|
||||
cmp r6, ip
|
||||
str r1, [r11], #4 @ C references.
|
||||
cmp r11, ip
|
||||
blo 1b
|
||||
#else
|
||||
|
||||
|
|
@ -208,12 +209,12 @@ not_angel:
|
|||
* Relocate entries in the GOT table. We only relocate
|
||||
* the entries that are outside the (relocated) BSS region.
|
||||
*/
|
||||
1: ldr r1, [r6, #0] @ relocate entries in the GOT
|
||||
1: ldr r1, [r11, #0] @ relocate entries in the GOT
|
||||
cmp r1, r2 @ entry < bss_start ||
|
||||
cmphs r3, r1 @ _end < entry
|
||||
addlo r1, r1, r0 @ table. This fixes up the
|
||||
str r1, [r6], #4 @ C references.
|
||||
cmp r6, ip
|
||||
str r1, [r11], #4 @ C references.
|
||||
cmp r11, ip
|
||||
blo 1b
|
||||
#endif
|
||||
|
||||
|
|
@ -239,6 +240,7 @@ not_relocated: mov r0, #0
|
|||
* Check to see if we will overwrite ourselves.
|
||||
* r4 = final kernel address
|
||||
* r5 = start of this image
|
||||
* r6 = size of decompressed image
|
||||
* r2 = end of malloc space (and therefore this image)
|
||||
* We basically want:
|
||||
* r4 >= r2 -> OK
|
||||
|
|
@ -246,8 +248,7 @@ not_relocated: mov r0, #0
|
|||
*/
|
||||
cmp r4, r2
|
||||
bhs wont_overwrite
|
||||
sub r3, sp, r5 @ > compressed kernel size
|
||||
add r0, r4, r3, lsl #2 @ allow for 4x expansion
|
||||
add r0, r4, r6
|
||||
cmp r0, r5
|
||||
bls wont_overwrite
|
||||
|
||||
|
|
@ -263,7 +264,6 @@ not_relocated: mov r0, #0
|
|||
* r1-r3 = unused
|
||||
* r4 = kernel execution address
|
||||
* r5 = decompressed kernel start
|
||||
* r6 = processor ID
|
||||
* r7 = architecture ID
|
||||
* r8 = atags pointer
|
||||
* r9-r12,r14 = corrupted
|
||||
|
|
@ -304,7 +304,8 @@ LC0: .word LC0 @ r1
|
|||
.word _end @ r3
|
||||
.word zreladdr @ r4
|
||||
.word _start @ r5
|
||||
.word _got_start @ r6
|
||||
.word _image_size @ r6
|
||||
.word _got_start @ r11
|
||||
.word _got_end @ ip
|
||||
.word user_stack+4096 @ sp
|
||||
LC1: .word reloc_end - reloc_start
|
||||
|
|
@ -328,7 +329,6 @@ params: ldr r0, =params_phys
|
|||
*
|
||||
* On entry,
|
||||
* r4 = kernel execution address
|
||||
* r6 = processor ID
|
||||
* r7 = architecture number
|
||||
* r8 = atags pointer
|
||||
* r9 = run-time address of "start" (???)
|
||||
|
|
@ -534,7 +534,6 @@ __common_mmu_cache_on:
|
|||
* r1-r3 = unused
|
||||
* r4 = kernel execution address
|
||||
* r5 = decompressed kernel start
|
||||
* r6 = processor ID
|
||||
* r7 = architecture ID
|
||||
* r8 = atags pointer
|
||||
* r9-r12,r14 = corrupted
|
||||
|
|
@ -573,19 +572,19 @@ call_kernel: bl cache_clean_flush
|
|||
* r1 = corrupted
|
||||
* r2 = corrupted
|
||||
* r3 = block offset
|
||||
* r6 = corrupted
|
||||
* r9 = corrupted
|
||||
* r12 = corrupted
|
||||
*/
|
||||
|
||||
call_cache_fn: adr r12, proc_types
|
||||
#ifdef CONFIG_CPU_CP15
|
||||
mrc p15, 0, r6, c0, c0 @ get processor ID
|
||||
mrc p15, 0, r9, c0, c0 @ get processor ID
|
||||
#else
|
||||
ldr r6, =CONFIG_PROCESSOR_ID
|
||||
ldr r9, =CONFIG_PROCESSOR_ID
|
||||
#endif
|
||||
1: ldr r1, [r12, #0] @ get value
|
||||
ldr r2, [r12, #4] @ get mask
|
||||
eor r1, r1, r6 @ (real ^ match)
|
||||
eor r1, r1, r9 @ (real ^ match)
|
||||
tst r1, r2 @ & mask
|
||||
ARM( addeq pc, r12, r3 ) @ call cache function
|
||||
THUMB( addeq r12, r3 )
|
||||
|
|
@ -767,8 +766,7 @@ proc_types:
|
|||
* Turn off the Cache and MMU. ARMv3 does not support
|
||||
* reading the control register, but ARMv4 does.
|
||||
*
|
||||
* On entry, r6 = processor ID
|
||||
* On exit, r0, r1, r2, r3, r12 corrupted
|
||||
* On exit, r0, r1, r2, r3, r9, r12 corrupted
|
||||
* This routine must preserve: r4, r6, r7
|
||||
*/
|
||||
.align 5
|
||||
|
|
@ -841,10 +839,8 @@ __armv3_mmu_cache_off:
|
|||
/*
|
||||
* Clean and flush the cache to maintain consistency.
|
||||
*
|
||||
* On entry,
|
||||
* r6 = processor ID
|
||||
* On exit,
|
||||
* r1, r2, r3, r11, r12 corrupted
|
||||
* r1, r2, r3, r9, r11, r12 corrupted
|
||||
* This routine must preserve:
|
||||
* r0, r4, r5, r6, r7
|
||||
*/
|
||||
|
|
@ -956,7 +952,7 @@ __armv4_mmu_cache_flush:
|
|||
mov r2, #64*1024 @ default: 32K dcache size (*2)
|
||||
mov r11, #32 @ default: 32 byte line size
|
||||
mrc p15, 0, r3, c0, c0, 1 @ read cache type
|
||||
teq r3, r6 @ cache ID register present?
|
||||
teq r3, r9 @ cache ID register present?
|
||||
beq no_cache_id
|
||||
mov r1, r3, lsr #18
|
||||
and r1, r1, #7
|
||||
|
|
|
|||
|
|
@ -36,6 +36,9 @@ SECTIONS
|
|||
|
||||
_etext = .;
|
||||
|
||||
/* Assume size of decompressed image is 4x the compressed image */
|
||||
_image_size = (_etext - _text) * 4;
|
||||
|
||||
_got_start = .;
|
||||
.got : { *(.got) }
|
||||
_got_end = .;
|
||||
|
|
|
|||
|
|
@ -887,8 +887,6 @@ static int sa1111_resume(struct platform_device *dev)
|
|||
if (!save)
|
||||
return 0;
|
||||
|
||||
spin_lock_irqsave(&sachip->lock, flags);
|
||||
|
||||
/*
|
||||
* Ensure that the SA1111 is still here.
|
||||
* FIXME: shouldn't do this here.
|
||||
|
|
@ -905,6 +903,13 @@ static int sa1111_resume(struct platform_device *dev)
|
|||
* First of all, wake up the chip.
|
||||
*/
|
||||
sa1111_wake(sachip);
|
||||
|
||||
/*
|
||||
* Only lock for write ops. Also, sa1111_wake must be called with
|
||||
* released spinlock!
|
||||
*/
|
||||
spin_lock_irqsave(&sachip->lock, flags);
|
||||
|
||||
sa1111_writel(0, sachip->base + SA1111_INTC + SA1111_INTEN0);
|
||||
sa1111_writel(0, sachip->base + SA1111_INTC + SA1111_INTEN1);
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
#
|
||||
# Automatically generated make config: don't edit
|
||||
# Linux kernel version: 2.6.32.9
|
||||
# Sat Dec 11 12:17:37 2010
|
||||
# Linux kernel version: 2.6.32.27
|
||||
# Sat Dec 18 09:08:43 2010
|
||||
#
|
||||
CONFIG_ARM=y
|
||||
CONFIG_SYS_SUPPORTS_APM_EMULATION=y
|
||||
|
|
@ -16,6 +16,7 @@ CONFIG_TRACE_IRQFLAGS_SUPPORT=y
|
|||
CONFIG_HARDIRQS_SW_RESEND=y
|
||||
CONFIG_GENERIC_IRQ_PROBE=y
|
||||
CONFIG_RWSEM_GENERIC_SPINLOCK=y
|
||||
CONFIG_ARCH_HAS_CPUFREQ=y
|
||||
CONFIG_GENERIC_HWEIGHT=y
|
||||
CONFIG_GENERIC_CALIBRATE_DELAY=y
|
||||
CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y
|
||||
|
|
@ -298,6 +299,21 @@ CONFIG_ATAGS_PROC=y
|
|||
#
|
||||
# CPU Power Management
|
||||
#
|
||||
CONFIG_CPU_FREQ=y
|
||||
CONFIG_CPU_FREQ_TABLE=y
|
||||
# CONFIG_CPU_FREQ_DEBUG is not set
|
||||
CONFIG_CPU_FREQ_STAT=y
|
||||
CONFIG_CPU_FREQ_STAT_DETAILS=y
|
||||
# CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE is not set
|
||||
# CONFIG_CPU_FREQ_DEFAULT_GOV_POWERSAVE is not set
|
||||
CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE=y
|
||||
# CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND is not set
|
||||
# CONFIG_CPU_FREQ_DEFAULT_GOV_CONSERVATIVE is not set
|
||||
CONFIG_CPU_FREQ_GOV_PERFORMANCE=y
|
||||
# CONFIG_CPU_FREQ_GOV_POWERSAVE is not set
|
||||
CONFIG_CPU_FREQ_GOV_USERSPACE=y
|
||||
CONFIG_CPU_FREQ_GOV_ONDEMAND=y
|
||||
# CONFIG_CPU_FREQ_GOV_CONSERVATIVE is not set
|
||||
# CONFIG_CPU_IDLE is not set
|
||||
|
||||
#
|
||||
|
|
@ -425,6 +441,10 @@ CONFIG_WIRELESS_EXT_SYSFS=y
|
|||
#
|
||||
# CFG80211 needs to be enabled for MAC80211
|
||||
#
|
||||
|
||||
#
|
||||
# Some wireless drivers require a rate control algorithm
|
||||
#
|
||||
# CONFIG_WIMAX is not set
|
||||
# CONFIG_RFKILL is not set
|
||||
# CONFIG_NET_9P is not set
|
||||
|
|
@ -515,6 +535,7 @@ CONFIG_MTD_NAND_IDS=y
|
|||
CONFIG_MTD_RKNAND=y
|
||||
CONFIG_MTD_NAND_RK29XX=y
|
||||
CONFIG_RKFTL_PAGECACHE_SIZE=64
|
||||
CONFIG_MTD_RKNAND_BUFFER=y
|
||||
# CONFIG_MTD_NAND_RK29XX_DEBUG is not set
|
||||
# CONFIG_MTD_ONENAND is not set
|
||||
|
||||
|
|
@ -533,6 +554,7 @@ CONFIG_BLK_DEV=y
|
|||
CONFIG_BLK_DEV_LOOP=y
|
||||
# CONFIG_BLK_DEV_CRYPTOLOOP is not set
|
||||
# CONFIG_BLK_DEV_NBD is not set
|
||||
# CONFIG_BLK_DEV_UB is not set
|
||||
# CONFIG_BLK_DEV_RAM is not set
|
||||
# CONFIG_CDROM_PKTCDVD is not set
|
||||
# CONFIG_ATA_OVER_ETH is not set
|
||||
|
|
@ -562,9 +584,42 @@ CONFIG_HAVE_IDE=y
|
|||
# SCSI device support
|
||||
#
|
||||
# CONFIG_RAID_ATTRS is not set
|
||||
# CONFIG_SCSI is not set
|
||||
# CONFIG_SCSI_DMA is not set
|
||||
CONFIG_SCSI=y
|
||||
CONFIG_SCSI_DMA=y
|
||||
# CONFIG_SCSI_TGT is not set
|
||||
# CONFIG_SCSI_NETLINK is not set
|
||||
CONFIG_SCSI_PROC_FS=y
|
||||
|
||||
#
|
||||
# SCSI support type (disk, tape, CD-ROM)
|
||||
#
|
||||
CONFIG_BLK_DEV_SD=y
|
||||
# CONFIG_CHR_DEV_ST is not set
|
||||
# CONFIG_CHR_DEV_OSST is not set
|
||||
# CONFIG_BLK_DEV_SR is not set
|
||||
# CONFIG_CHR_DEV_SG is not set
|
||||
# CONFIG_CHR_DEV_SCH is not set
|
||||
CONFIG_SCSI_MULTI_LUN=y
|
||||
# CONFIG_SCSI_CONSTANTS is not set
|
||||
# CONFIG_SCSI_LOGGING is not set
|
||||
# CONFIG_SCSI_SCAN_ASYNC is not set
|
||||
CONFIG_SCSI_WAIT_SCAN=m
|
||||
|
||||
#
|
||||
# SCSI Transports
|
||||
#
|
||||
# CONFIG_SCSI_SPI_ATTRS is not set
|
||||
# CONFIG_SCSI_FC_ATTRS is not set
|
||||
# CONFIG_SCSI_ISCSI_ATTRS is not set
|
||||
# CONFIG_SCSI_SAS_LIBSAS is not set
|
||||
# CONFIG_SCSI_SRP_ATTRS is not set
|
||||
CONFIG_SCSI_LOWLEVEL=y
|
||||
# CONFIG_ISCSI_TCP is not set
|
||||
# CONFIG_LIBFC is not set
|
||||
# CONFIG_LIBFCOE is not set
|
||||
# CONFIG_SCSI_DEBUG is not set
|
||||
# CONFIG_SCSI_DH is not set
|
||||
# CONFIG_SCSI_OSD_INITIATOR is not set
|
||||
# CONFIG_ATA is not set
|
||||
# CONFIG_MD is not set
|
||||
CONFIG_NETDEVICES=y
|
||||
|
|
@ -620,6 +675,7 @@ CONFIG_WLAN=y
|
|||
# CONFIG_WLAN_PRE80211 is not set
|
||||
CONFIG_WLAN_80211=y
|
||||
# CONFIG_LIBERTAS is not set
|
||||
# CONFIG_USB_ZD1201 is not set
|
||||
# CONFIG_HOSTAP is not set
|
||||
CONFIG_BCM4329=m
|
||||
CONFIG_BCM4329_FW_PATH="/etc/firmware/fw_bcm4329.bin"
|
||||
|
|
@ -628,6 +684,15 @@ CONFIG_BCM4329_NVRAM_PATH="/etc/firmware/nvram_bcm4329_B23.txt"
|
|||
#
|
||||
# Enable WiMAX (Networking options) to see the WiMAX drivers
|
||||
#
|
||||
|
||||
#
|
||||
# USB Network Adapters
|
||||
#
|
||||
# CONFIG_USB_CATC is not set
|
||||
# CONFIG_USB_KAWETH is not set
|
||||
# CONFIG_USB_PEGASUS is not set
|
||||
# CONFIG_USB_RTL8150 is not set
|
||||
# CONFIG_USB_USBNET is not set
|
||||
# CONFIG_WAN is not set
|
||||
# CONFIG_PPP is not set
|
||||
# CONFIG_SLIP is not set
|
||||
|
|
@ -695,6 +760,7 @@ CONFIG_TOUCHSCREEN_XPT2046_SPI_NOCHOOSE=y
|
|||
# CONFIG_TOUCHSCREEN_SYNAPTICS_I2C_RMI is not set
|
||||
# CONFIG_TOUCHSCREEN_TOUCHRIGHT is not set
|
||||
# CONFIG_TOUCHSCREEN_TOUCHWIN is not set
|
||||
# CONFIG_TOUCHSCREEN_USB_COMPOSITE is not set
|
||||
# CONFIG_TOUCHSCREEN_TOUCHIT213 is not set
|
||||
# CONFIG_TOUCHSCREEN_TSC2007 is not set
|
||||
# CONFIG_TOUCHSCREEN_W90X900 is not set
|
||||
|
|
@ -863,8 +929,131 @@ CONFIG_SSB_POSSIBLE=y
|
|||
# CONFIG_MFD_PCF50633 is not set
|
||||
# CONFIG_AB3100_CORE is not set
|
||||
# CONFIG_REGULATOR is not set
|
||||
# CONFIG_MEDIA_SUPPORT is not set
|
||||
CONFIG_MEDIA_SUPPORT=y
|
||||
|
||||
#
|
||||
# Multimedia core support
|
||||
#
|
||||
CONFIG_VIDEO_DEV=y
|
||||
CONFIG_VIDEO_V4L2_COMMON=y
|
||||
CONFIG_VIDEO_ALLOW_V4L1=y
|
||||
CONFIG_VIDEO_V4L1_COMPAT=y
|
||||
# CONFIG_DVB_CORE is not set
|
||||
CONFIG_VIDEO_MEDIA=y
|
||||
|
||||
#
|
||||
# Multimedia drivers
|
||||
#
|
||||
# CONFIG_MEDIA_ATTACH is not set
|
||||
CONFIG_MEDIA_TUNER=y
|
||||
# CONFIG_MEDIA_TUNER_CUSTOMISE is not set
|
||||
CONFIG_MEDIA_TUNER_SIMPLE=y
|
||||
CONFIG_MEDIA_TUNER_TDA8290=y
|
||||
CONFIG_MEDIA_TUNER_TDA9887=y
|
||||
CONFIG_MEDIA_TUNER_TEA5761=y
|
||||
CONFIG_MEDIA_TUNER_TEA5767=y
|
||||
CONFIG_MEDIA_TUNER_MT20XX=y
|
||||
CONFIG_MEDIA_TUNER_XC2028=y
|
||||
CONFIG_MEDIA_TUNER_XC5000=y
|
||||
CONFIG_MEDIA_TUNER_MC44S803=y
|
||||
CONFIG_VIDEO_V4L2=y
|
||||
CONFIG_VIDEO_V4L1=y
|
||||
CONFIG_VIDEOBUF_GEN=y
|
||||
CONFIG_VIDEOBUF_DMA_CONTIG=y
|
||||
CONFIG_VIDEO_CAPTURE_DRIVERS=y
|
||||
# CONFIG_VIDEO_ADV_DEBUG is not set
|
||||
# CONFIG_VIDEO_FIXED_MINOR_RANGES is not set
|
||||
CONFIG_VIDEO_HELPER_CHIPS_AUTO=y
|
||||
# CONFIG_VIDEO_VIVI is not set
|
||||
# CONFIG_VIDEO_CPIA is not set
|
||||
# CONFIG_VIDEO_CPIA2 is not set
|
||||
# CONFIG_VIDEO_SAA5246A is not set
|
||||
# CONFIG_VIDEO_SAA5249 is not set
|
||||
CONFIG_SOC_CAMERA=y
|
||||
# CONFIG_SOC_CAMERA_MT9M001 is not set
|
||||
# CONFIG_SOC_CAMERA_MT9M111 is not set
|
||||
# CONFIG_SOC_CAMERA_MT9T031 is not set
|
||||
# CONFIG_SOC_CAMERA_MT9V022 is not set
|
||||
# CONFIG_SOC_CAMERA_TW9910 is not set
|
||||
# CONFIG_SOC_CAMERA_PLATFORM is not set
|
||||
# CONFIG_SOC_CAMERA_OV772X is not set
|
||||
# CONFIG_SOC_CAMERA_OV2655 is not set
|
||||
CONFIG_SOC_CAMERA_OV2659=y
|
||||
# CONFIG_SOC_CAMERA_OV9650 is not set
|
||||
# CONFIG_SOC_CAMERA_OV3640 is not set
|
||||
CONFIG_SOC_CAMERA_OV5642=y
|
||||
CONFIG_OV5642_AUTOFOCUS=y
|
||||
# CONFIG_OV5642_FIXEDFOCUS is not set
|
||||
# CONFIG_VIDEO_SH_MOBILE_CEU is not set
|
||||
CONFIG_VIDEO_RK29=y
|
||||
CONFIG_VIDEO_RK29_WORK_ONEFRAME=y
|
||||
# CONFIG_VIDEO_RK29_WORK_PINGPONG is not set
|
||||
CONFIG_VIDEO_RK29_WORK_IPP=y
|
||||
# CONFIG_VIDEO_RK29_WORK_NOT_IPP is not set
|
||||
CONFIG_V4L_USB_DRIVERS=y
|
||||
# CONFIG_USB_VIDEO_CLASS is not set
|
||||
CONFIG_USB_VIDEO_CLASS_INPUT_EVDEV=y
|
||||
CONFIG_USB_GSPCA=m
|
||||
# CONFIG_USB_M5602 is not set
|
||||
# CONFIG_USB_STV06XX is not set
|
||||
# CONFIG_USB_GL860 is not set
|
||||
# CONFIG_USB_GSPCA_CONEX is not set
|
||||
# CONFIG_USB_GSPCA_ETOMS is not set
|
||||
# CONFIG_USB_GSPCA_FINEPIX is not set
|
||||
# CONFIG_USB_GSPCA_JEILINJ is not set
|
||||
# CONFIG_USB_GSPCA_MARS is not set
|
||||
# CONFIG_USB_GSPCA_MR97310A is not set
|
||||
# CONFIG_USB_GSPCA_OV519 is not set
|
||||
# CONFIG_USB_GSPCA_OV534 is not set
|
||||
# CONFIG_USB_GSPCA_PAC207 is not set
|
||||
# CONFIG_USB_GSPCA_PAC7311 is not set
|
||||
# CONFIG_USB_GSPCA_SN9C20X is not set
|
||||
# CONFIG_USB_GSPCA_SONIXB is not set
|
||||
# CONFIG_USB_GSPCA_SONIXJ is not set
|
||||
# CONFIG_USB_GSPCA_SPCA500 is not set
|
||||
# CONFIG_USB_GSPCA_SPCA501 is not set
|
||||
# CONFIG_USB_GSPCA_SPCA505 is not set
|
||||
# CONFIG_USB_GSPCA_SPCA506 is not set
|
||||
# CONFIG_USB_GSPCA_SPCA508 is not set
|
||||
# CONFIG_USB_GSPCA_SPCA561 is not set
|
||||
# CONFIG_USB_GSPCA_SQ905 is not set
|
||||
# CONFIG_USB_GSPCA_SQ905C is not set
|
||||
# CONFIG_USB_GSPCA_STK014 is not set
|
||||
# CONFIG_USB_GSPCA_SUNPLUS is not set
|
||||
# CONFIG_USB_GSPCA_T613 is not set
|
||||
# CONFIG_USB_GSPCA_TV8532 is not set
|
||||
# CONFIG_USB_GSPCA_VC032X is not set
|
||||
# CONFIG_USB_GSPCA_ZC3XX is not set
|
||||
# CONFIG_VIDEO_PVRUSB2 is not set
|
||||
# CONFIG_VIDEO_HDPVR is not set
|
||||
# CONFIG_VIDEO_EM28XX is not set
|
||||
# CONFIG_VIDEO_CX231XX is not set
|
||||
# CONFIG_VIDEO_USBVISION is not set
|
||||
# CONFIG_USB_VICAM is not set
|
||||
# CONFIG_USB_IBMCAM is not set
|
||||
# CONFIG_USB_KONICAWC is not set
|
||||
# CONFIG_USB_QUICKCAM_MESSENGER is not set
|
||||
# CONFIG_USB_ET61X251 is not set
|
||||
# CONFIG_VIDEO_OVCAMCHIP is not set
|
||||
# CONFIG_USB_OV511 is not set
|
||||
# CONFIG_USB_SE401 is not set
|
||||
# CONFIG_USB_SN9C102 is not set
|
||||
# CONFIG_USB_STV680 is not set
|
||||
# CONFIG_USB_ZC0301 is not set
|
||||
# CONFIG_USB_PWC is not set
|
||||
CONFIG_USB_PWC_INPUT_EVDEV=y
|
||||
# CONFIG_USB_ZR364XX is not set
|
||||
# CONFIG_USB_STKWEBCAM is not set
|
||||
# CONFIG_USB_S2255 is not set
|
||||
CONFIG_RADIO_ADAPTERS=y
|
||||
# CONFIG_I2C_SI4713 is not set
|
||||
# CONFIG_RADIO_SI4713 is not set
|
||||
# CONFIG_USB_DSBR is not set
|
||||
# CONFIG_RADIO_SI470X is not set
|
||||
# CONFIG_USB_MR800 is not set
|
||||
# CONFIG_RADIO_TEA5764 is not set
|
||||
# CONFIG_SMS_SIANO_MDTV is not set
|
||||
# CONFIG_DAB is not set
|
||||
|
||||
#
|
||||
# Graphics support
|
||||
|
|
@ -974,6 +1163,9 @@ CONFIG_SND_JACK=y
|
|||
# CONFIG_SND_EMU10K1_SEQ is not set
|
||||
# CONFIG_SND_DRIVERS is not set
|
||||
# CONFIG_SND_ARM is not set
|
||||
CONFIG_SND_USB=y
|
||||
# CONFIG_SND_USB_AUDIO is not set
|
||||
# CONFIG_SND_USB_CAIAQ is not set
|
||||
CONFIG_SND_SOC=y
|
||||
CONFIG_SND_RK29_SOC=y
|
||||
CONFIG_SND_RK29_SOC_I2S=y
|
||||
|
|
@ -988,7 +1180,208 @@ CONFIG_SND_SOC_I2C_AND_SPI=y
|
|||
CONFIG_SND_SOC_WM8900=y
|
||||
# CONFIG_SOUND_PRIME is not set
|
||||
# CONFIG_HID_SUPPORT is not set
|
||||
# CONFIG_USB_SUPPORT is not set
|
||||
CONFIG_USB_SUPPORT=y
|
||||
CONFIG_USB_ARCH_HAS_HCD=y
|
||||
# CONFIG_USB_ARCH_HAS_OHCI is not set
|
||||
# CONFIG_USB_ARCH_HAS_EHCI is not set
|
||||
CONFIG_USB=y
|
||||
# CONFIG_USB_DEBUG is not set
|
||||
CONFIG_USB_ANNOUNCE_NEW_DEVICES=y
|
||||
|
||||
#
|
||||
# Miscellaneous USB options
|
||||
#
|
||||
# CONFIG_USB_DEVICEFS is not set
|
||||
CONFIG_USB_DEVICE_CLASS=y
|
||||
# CONFIG_USB_DYNAMIC_MINORS is not set
|
||||
# CONFIG_USB_SUSPEND is not set
|
||||
# CONFIG_USB_OTG is not set
|
||||
# CONFIG_USB_OTG_WHITELIST is not set
|
||||
CONFIG_USB_OTG_BLACKLIST_HUB=y
|
||||
# CONFIG_USB_MON is not set
|
||||
# CONFIG_USB_WUSB is not set
|
||||
# CONFIG_USB_WUSB_CBAF is not set
|
||||
|
||||
#
|
||||
# USB Host Controller Drivers
|
||||
#
|
||||
# CONFIG_USB_C67X00_HCD is not set
|
||||
# CONFIG_USB_OXU210HP_HCD is not set
|
||||
# CONFIG_USB_ISP116X_HCD is not set
|
||||
# CONFIG_USB_ISP1760_HCD is not set
|
||||
# CONFIG_USB_ISP1362_HCD is not set
|
||||
# CONFIG_USB_SL811_HCD is not set
|
||||
# CONFIG_USB_R8A66597_HCD is not set
|
||||
# CONFIG_USB_HWA_HCD is not set
|
||||
# CONFIG_USB_MUSB_HDRC is not set
|
||||
# CONFIG_USB_GADGET_MUSB_HDRC is not set
|
||||
|
||||
#
|
||||
# USB Device Class drivers
|
||||
#
|
||||
# CONFIG_USB_ACM is not set
|
||||
# CONFIG_USB_PRINTER is not set
|
||||
# CONFIG_USB_WDM is not set
|
||||
# CONFIG_USB_TMC is not set
|
||||
|
||||
#
|
||||
# NOTE: USB_STORAGE depends on SCSI but BLK_DEV_SD may
|
||||
#
|
||||
|
||||
#
|
||||
# also be needed; see USB_STORAGE Help for more info
|
||||
#
|
||||
CONFIG_USB_STORAGE=y
|
||||
# CONFIG_USB_STORAGE_DEBUG is not set
|
||||
# CONFIG_USB_STORAGE_DATAFAB is not set
|
||||
# CONFIG_USB_STORAGE_FREECOM is not set
|
||||
# CONFIG_USB_STORAGE_ISD200 is not set
|
||||
# CONFIG_USB_STORAGE_USBAT is not set
|
||||
# CONFIG_USB_STORAGE_SDDR09 is not set
|
||||
# CONFIG_USB_STORAGE_SDDR55 is not set
|
||||
# CONFIG_USB_STORAGE_JUMPSHOT is not set
|
||||
# CONFIG_USB_STORAGE_ALAUDA is not set
|
||||
# CONFIG_USB_STORAGE_ONETOUCH is not set
|
||||
# CONFIG_USB_STORAGE_KARMA is not set
|
||||
# CONFIG_USB_STORAGE_CYPRESS_ATACB is not set
|
||||
# CONFIG_USB_LIBUSUAL is not set
|
||||
|
||||
#
|
||||
# USB Imaging devices
|
||||
#
|
||||
# CONFIG_USB_MDC800 is not set
|
||||
# CONFIG_USB_MICROTEK is not set
|
||||
|
||||
#
|
||||
# USB port drivers
|
||||
#
|
||||
CONFIG_USB_SERIAL=y
|
||||
# CONFIG_USB_SERIAL_CONSOLE is not set
|
||||
# CONFIG_USB_EZUSB is not set
|
||||
CONFIG_USB_SERIAL_GENERIC=y
|
||||
# CONFIG_USB_SERIAL_AIRCABLE is not set
|
||||
# CONFIG_USB_SERIAL_ARK3116 is not set
|
||||
# CONFIG_USB_SERIAL_BELKIN is not set
|
||||
# CONFIG_USB_SERIAL_CH341 is not set
|
||||
# CONFIG_USB_SERIAL_WHITEHEAT is not set
|
||||
# CONFIG_USB_SERIAL_DIGI_ACCELEPORT is not set
|
||||
# CONFIG_USB_SERIAL_CP210X is not set
|
||||
# CONFIG_USB_SERIAL_CYPRESS_M8 is not set
|
||||
# CONFIG_USB_SERIAL_EMPEG is not set
|
||||
# CONFIG_USB_SERIAL_FTDI_SIO is not set
|
||||
# CONFIG_USB_SERIAL_FUNSOFT is not set
|
||||
# CONFIG_USB_SERIAL_VISOR is not set
|
||||
# CONFIG_USB_SERIAL_IPAQ is not set
|
||||
# CONFIG_USB_SERIAL_IR is not set
|
||||
# CONFIG_USB_SERIAL_EDGEPORT is not set
|
||||
# CONFIG_USB_SERIAL_EDGEPORT_TI is not set
|
||||
# CONFIG_USB_SERIAL_GARMIN is not set
|
||||
# CONFIG_USB_SERIAL_IPW is not set
|
||||
# CONFIG_USB_SERIAL_IUU is not set
|
||||
# CONFIG_USB_SERIAL_KEYSPAN_PDA is not set
|
||||
# CONFIG_USB_SERIAL_KEYSPAN is not set
|
||||
# CONFIG_USB_SERIAL_KLSI is not set
|
||||
# CONFIG_USB_SERIAL_KOBIL_SCT is not set
|
||||
# CONFIG_USB_SERIAL_MCT_U232 is not set
|
||||
# CONFIG_USB_SERIAL_MOS7720 is not set
|
||||
# CONFIG_USB_SERIAL_MOS7840 is not set
|
||||
# CONFIG_USB_SERIAL_MOTOROLA is not set
|
||||
# CONFIG_USB_SERIAL_NAVMAN is not set
|
||||
# CONFIG_USB_SERIAL_PL2303 is not set
|
||||
# CONFIG_USB_SERIAL_OTI6858 is not set
|
||||
# CONFIG_USB_SERIAL_QUALCOMM is not set
|
||||
# CONFIG_USB_SERIAL_SPCP8X5 is not set
|
||||
# CONFIG_USB_SERIAL_HP4X is not set
|
||||
# CONFIG_USB_SERIAL_SAFE is not set
|
||||
# CONFIG_USB_SERIAL_SIEMENS_MPI is not set
|
||||
# CONFIG_USB_SERIAL_SIERRAWIRELESS is not set
|
||||
# CONFIG_USB_SERIAL_SYMBOL is not set
|
||||
# CONFIG_USB_SERIAL_TI is not set
|
||||
# CONFIG_USB_SERIAL_CYBERJACK is not set
|
||||
# CONFIG_USB_SERIAL_XIRCOM is not set
|
||||
CONFIG_USB_SERIAL_OPTION=y
|
||||
# CONFIG_USB_SERIAL_OMNINET is not set
|
||||
# CONFIG_USB_SERIAL_OPTICON is not set
|
||||
# CONFIG_USB_SERIAL_DEBUG is not set
|
||||
|
||||
#
|
||||
# USB Miscellaneous drivers
|
||||
#
|
||||
# CONFIG_USB_EMI62 is not set
|
||||
# CONFIG_USB_EMI26 is not set
|
||||
# CONFIG_USB_ADUTUX is not set
|
||||
# CONFIG_USB_SEVSEG is not set
|
||||
# CONFIG_USB_RIO500 is not set
|
||||
# CONFIG_USB_LEGOTOWER is not set
|
||||
# CONFIG_USB_LCD is not set
|
||||
# CONFIG_USB_BERRY_CHARGE is not set
|
||||
# CONFIG_USB_LED is not set
|
||||
# CONFIG_USB_CYPRESS_CY7C63 is not set
|
||||
# CONFIG_USB_CYTHERM is not set
|
||||
# CONFIG_USB_IDMOUSE is not set
|
||||
# CONFIG_USB_FTDI_ELAN is not set
|
||||
# CONFIG_USB_APPLEDISPLAY is not set
|
||||
# CONFIG_USB_LD is not set
|
||||
# CONFIG_USB_TRANCEVIBRATOR is not set
|
||||
# CONFIG_USB_IOWARRIOR is not set
|
||||
# CONFIG_USB_TEST is not set
|
||||
# CONFIG_USB_ISIGHTFW is not set
|
||||
# CONFIG_USB_VST is not set
|
||||
CONFIG_USB_GADGET=y
|
||||
# CONFIG_USB_GADGET_DEBUG is not set
|
||||
# CONFIG_USB_GADGET_DEBUG_FILES is not set
|
||||
CONFIG_USB_GADGET_VBUS_DRAW=2
|
||||
CONFIG_USB_GADGET_SELECTED=y
|
||||
# CONFIG_USB_GADGET_AT91 is not set
|
||||
# CONFIG_USB_GADGET_ATMEL_USBA is not set
|
||||
# CONFIG_USB_GADGET_FSL_USB2 is not set
|
||||
# CONFIG_USB_GADGET_LH7A40X is not set
|
||||
# CONFIG_USB_GADGET_OMAP is not set
|
||||
# CONFIG_USB_GADGET_PXA25X is not set
|
||||
# CONFIG_USB_GADGET_R8A66597 is not set
|
||||
# CONFIG_USB_GADGET_PXA27X is not set
|
||||
# CONFIG_USB_GADGET_S3C_HSOTG is not set
|
||||
# CONFIG_USB_GADGET_IMX is not set
|
||||
# CONFIG_USB_GADGET_S3C2410 is not set
|
||||
# CONFIG_USB_GADGET_M66592 is not set
|
||||
# CONFIG_USB_GADGET_AMD5536UDC is not set
|
||||
# CONFIG_USB_GADGET_FSL_QE is not set
|
||||
# CONFIG_USB_GADGET_CI13XXX is not set
|
||||
# CONFIG_USB_GADGET_NET2280 is not set
|
||||
# CONFIG_USB_GADGET_GOKU is not set
|
||||
# CONFIG_USB_GADGET_LANGWELL is not set
|
||||
CONFIG_USB_GADGET_DWC_OTG=y
|
||||
CONFIG_USB_DWC_OTG=y
|
||||
# CONFIG_USB_GADGET_DUMMY_HCD is not set
|
||||
CONFIG_USB_GADGET_DUALSPEED=y
|
||||
# CONFIG_USB_ZERO is not set
|
||||
# CONFIG_USB_AUDIO is not set
|
||||
# CONFIG_USB_ETH is not set
|
||||
# CONFIG_USB_GADGETFS is not set
|
||||
# CONFIG_USB_FILE_STORAGE is not set
|
||||
# CONFIG_USB_G_SERIAL is not set
|
||||
# CONFIG_USB_MIDI_GADGET is not set
|
||||
# CONFIG_USB_G_PRINTER is not set
|
||||
CONFIG_USB_ANDROID=y
|
||||
# CONFIG_USB_ANDROID_ACM is not set
|
||||
CONFIG_USB_ANDROID_ADB=y
|
||||
CONFIG_USB_ANDROID_MASS_STORAGE=y
|
||||
# CONFIG_USB_ANDROID_RNDIS is not set
|
||||
# CONFIG_USB_CDC_COMPOSITE is not set
|
||||
|
||||
#
|
||||
# OTG and related infrastructure
|
||||
#
|
||||
# CONFIG_USB_GPIO_VBUS is not set
|
||||
# CONFIG_NOP_USB_XCEIV is not set
|
||||
CONFIG_USB11_HOST=y
|
||||
CONFIG_USB20_HOST=y
|
||||
CONFIG_USB20_OTG=y
|
||||
# CONFIG_DWC_OTG_HOST_ONLY is not set
|
||||
CONFIG_DWC_OTG_DEVICE_ONLY=y
|
||||
CONFIG_DWC_CONN_EN=y
|
||||
# CONFIG_DWC_OTG_DEBUG is not set
|
||||
CONFIG_DWC_OTG=y
|
||||
CONFIG_MMC=y
|
||||
# CONFIG_MMC_DEBUG is not set
|
||||
# CONFIG_MMC_UNSAFE_RESUME is not set
|
||||
|
|
@ -1091,7 +1484,12 @@ CONFIG_RTC_HYM8563=y
|
|||
#
|
||||
CONFIG_STAGING=y
|
||||
# CONFIG_STAGING_EXCLUDE_BUILD is not set
|
||||
# CONFIG_USB_IP_COMMON is not set
|
||||
# CONFIG_PRISM2_USB is not set
|
||||
# CONFIG_ECHO is not set
|
||||
# CONFIG_COMEDI is not set
|
||||
# CONFIG_ASUS_OLED is not set
|
||||
# CONFIG_TRANZPORT is not set
|
||||
|
||||
#
|
||||
# Android
|
||||
|
|
@ -1121,6 +1519,11 @@ CONFIG_ANDROID_LOW_MEMORY_KILLER=y
|
|||
# CONFIG_DST is not set
|
||||
# CONFIG_POHMELFS is not set
|
||||
# CONFIG_PLAN9AUTH is not set
|
||||
# CONFIG_LINE6_USB is not set
|
||||
# CONFIG_USB_SERIAL_QUATECH2 is not set
|
||||
# CONFIG_USB_SERIAL_QUATECH_USB2 is not set
|
||||
# CONFIG_VT6656 is not set
|
||||
# CONFIG_FB_UDL is not set
|
||||
|
||||
#
|
||||
# RAR Register Driver
|
||||
|
|
@ -1148,6 +1551,11 @@ CONFIG_ANDROID_LOW_MEMORY_KILLER=y
|
|||
#
|
||||
CONFIG_VIVANTE=y
|
||||
|
||||
#
|
||||
# IPP
|
||||
#
|
||||
CONFIG_RK29_IPP=y
|
||||
|
||||
#
|
||||
# CMMB
|
||||
#
|
||||
|
|
|
|||
|
|
@ -215,7 +215,7 @@
|
|||
@ Slightly optimised to avoid incrementing the pointer twice
|
||||
usraccoff \instr, \reg, \ptr, \inc, 0, \cond, \abort
|
||||
.if \rept == 2
|
||||
usraccoff \instr, \reg, \ptr, \inc, 4, \cond, \abort
|
||||
usraccoff \instr, \reg, \ptr, \inc, \inc, \cond, \abort
|
||||
.endif
|
||||
|
||||
add\cond \ptr, #\rept * \inc
|
||||
|
|
|
|||
|
|
@ -150,15 +150,24 @@ struct pt_regs {
|
|||
*/
|
||||
static inline int valid_user_regs(struct pt_regs *regs)
|
||||
{
|
||||
if (user_mode(regs) && (regs->ARM_cpsr & PSR_I_BIT) == 0) {
|
||||
regs->ARM_cpsr &= ~(PSR_F_BIT | PSR_A_BIT);
|
||||
return 1;
|
||||
unsigned long mode = regs->ARM_cpsr & MODE_MASK;
|
||||
|
||||
/*
|
||||
* Always clear the F (FIQ) and A (delayed abort) bits
|
||||
*/
|
||||
regs->ARM_cpsr &= ~(PSR_F_BIT | PSR_A_BIT);
|
||||
|
||||
if ((regs->ARM_cpsr & PSR_I_BIT) == 0) {
|
||||
if (mode == USR_MODE)
|
||||
return 1;
|
||||
if (elf_hwcap & HWCAP_26BIT && mode == USR26_MODE)
|
||||
return 1;
|
||||
}
|
||||
|
||||
/*
|
||||
* Force CPSR to something logical...
|
||||
*/
|
||||
regs->ARM_cpsr &= PSR_f | PSR_s | (PSR_x & ~PSR_A_BIT) | PSR_T_BIT | MODE32_BIT;
|
||||
regs->ARM_cpsr &= PSR_f | PSR_s | PSR_x | PSR_T_BIT | MODE32_BIT;
|
||||
if (!(elf_hwcap & HWCAP_26BIT))
|
||||
regs->ARM_cpsr |= USR_MODE;
|
||||
|
||||
|
|
|
|||
|
|
@ -369,7 +369,11 @@ static inline void local_flush_tlb_mm(struct mm_struct *mm)
|
|||
if (tlb_flag(TLB_V6_I_ASID))
|
||||
asm("mcr p15, 0, %0, c8, c5, 2" : : "r" (asid) : "cc");
|
||||
if (tlb_flag(TLB_V7_UIS_ASID))
|
||||
#ifdef CONFIG_ARM_ERRATA_720789
|
||||
asm("mcr p15, 0, %0, c8, c3, 0" : : "r" (zero) : "cc");
|
||||
#else
|
||||
asm("mcr p15, 0, %0, c8, c3, 2" : : "r" (asid) : "cc");
|
||||
#endif
|
||||
|
||||
if (tlb_flag(TLB_BTB)) {
|
||||
/* flush the branch target cache */
|
||||
|
|
@ -409,7 +413,11 @@ local_flush_tlb_page(struct vm_area_struct *vma, unsigned long uaddr)
|
|||
if (tlb_flag(TLB_V6_I_PAGE))
|
||||
asm("mcr p15, 0, %0, c8, c5, 1" : : "r" (uaddr) : "cc");
|
||||
if (tlb_flag(TLB_V7_UIS_PAGE))
|
||||
#ifdef CONFIG_ARM_ERRATA_720789
|
||||
asm("mcr p15, 0, %0, c8, c3, 3" : : "r" (uaddr & PAGE_MASK) : "cc");
|
||||
#else
|
||||
asm("mcr p15, 0, %0, c8, c3, 1" : : "r" (uaddr) : "cc");
|
||||
#endif
|
||||
|
||||
if (tlb_flag(TLB_BTB)) {
|
||||
/* flush the branch target cache */
|
||||
|
|
|
|||
|
|
@ -382,11 +382,13 @@ ENDPROC(sys_clone_wrapper)
|
|||
|
||||
sys_sigreturn_wrapper:
|
||||
add r0, sp, #S_OFF
|
||||
mov why, #0 @ prevent syscall restart handling
|
||||
b sys_sigreturn
|
||||
ENDPROC(sys_sigreturn_wrapper)
|
||||
|
||||
sys_rt_sigreturn_wrapper:
|
||||
add r0, sp, #S_OFF
|
||||
mov why, #0 @ prevent syscall restart handling
|
||||
b sys_rt_sigreturn
|
||||
ENDPROC(sys_rt_sigreturn_wrapper)
|
||||
|
||||
|
|
|
|||
|
|
@ -583,13 +583,14 @@ static void __kprobes emulate_ldr(struct kprobe *p, struct pt_regs *regs)
|
|||
{
|
||||
insn_llret_3arg_fn_t *i_fn = (insn_llret_3arg_fn_t *)&p->ainsn.insn[0];
|
||||
kprobe_opcode_t insn = p->opcode;
|
||||
long ppc = (long)p->addr + 8;
|
||||
union reg_pair fnr;
|
||||
int rd = (insn >> 12) & 0xf;
|
||||
int rn = (insn >> 16) & 0xf;
|
||||
int rm = insn & 0xf;
|
||||
long rdv;
|
||||
long rnv = regs->uregs[rn];
|
||||
long rmv = regs->uregs[rm]; /* rm/rmv may be invalid, don't care. */
|
||||
long rnv = (rn == 15) ? ppc : regs->uregs[rn];
|
||||
long rmv = (rm == 15) ? ppc : regs->uregs[rm];
|
||||
long cpsr = regs->ARM_cpsr;
|
||||
|
||||
fnr.dr = insnslot_llret_3arg_rflags(rnv, 0, rmv, cpsr, i_fn);
|
||||
|
|
|
|||
|
|
@ -174,8 +174,8 @@ ENDPROC(_find_next_bit_be)
|
|||
*/
|
||||
.L_found:
|
||||
#if __LINUX_ARM_ARCH__ >= 5
|
||||
rsb r1, r3, #0
|
||||
and r3, r3, r1
|
||||
rsb r0, r3, #0
|
||||
and r3, r3, r0
|
||||
clz r3, r3
|
||||
rsb r3, r3, #31
|
||||
add r0, r2, r3
|
||||
|
|
@ -190,5 +190,7 @@ ENDPROC(_find_next_bit_be)
|
|||
addeq r2, r2, #1
|
||||
mov r0, r2
|
||||
#endif
|
||||
cmp r1, r0 @ Clamp to maxbit
|
||||
movlo r0, r1
|
||||
mov pc, lr
|
||||
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ static struct resource hdmac_resources[] = {
|
|||
.end = AT91_BASE_SYS + AT91_DMA + SZ_512 - 1,
|
||||
.flags = IORESOURCE_MEM,
|
||||
},
|
||||
[2] = {
|
||||
[1] = {
|
||||
.start = AT91SAM9G45_ID_DMA,
|
||||
.end = AT91SAM9G45_ID_DMA,
|
||||
.flags = IORESOURCE_IRQ,
|
||||
|
|
|
|||
|
|
@ -37,6 +37,10 @@
|
|||
#define SYSTEM_REV_S_USES_VAUX3 0x8
|
||||
|
||||
static int board_keymap[] = {
|
||||
/*
|
||||
* Note that KEY(x, 8, KEY_XXX) entries represent "entrire row
|
||||
* connected to the ground" matrix state.
|
||||
*/
|
||||
KEY(0, 0, KEY_Q),
|
||||
KEY(0, 1, KEY_O),
|
||||
KEY(0, 2, KEY_P),
|
||||
|
|
@ -44,6 +48,7 @@ static int board_keymap[] = {
|
|||
KEY(0, 4, KEY_BACKSPACE),
|
||||
KEY(0, 6, KEY_A),
|
||||
KEY(0, 7, KEY_S),
|
||||
|
||||
KEY(1, 0, KEY_W),
|
||||
KEY(1, 1, KEY_D),
|
||||
KEY(1, 2, KEY_F),
|
||||
|
|
@ -52,6 +57,7 @@ static int board_keymap[] = {
|
|||
KEY(1, 5, KEY_J),
|
||||
KEY(1, 6, KEY_K),
|
||||
KEY(1, 7, KEY_L),
|
||||
|
||||
KEY(2, 0, KEY_E),
|
||||
KEY(2, 1, KEY_DOT),
|
||||
KEY(2, 2, KEY_UP),
|
||||
|
|
@ -59,6 +65,8 @@ static int board_keymap[] = {
|
|||
KEY(2, 5, KEY_Z),
|
||||
KEY(2, 6, KEY_X),
|
||||
KEY(2, 7, KEY_C),
|
||||
KEY(2, 8, KEY_F9),
|
||||
|
||||
KEY(3, 0, KEY_R),
|
||||
KEY(3, 1, KEY_V),
|
||||
KEY(3, 2, KEY_B),
|
||||
|
|
@ -67,20 +75,23 @@ static int board_keymap[] = {
|
|||
KEY(3, 5, KEY_SPACE),
|
||||
KEY(3, 6, KEY_SPACE),
|
||||
KEY(3, 7, KEY_LEFT),
|
||||
|
||||
KEY(4, 0, KEY_T),
|
||||
KEY(4, 1, KEY_DOWN),
|
||||
KEY(4, 2, KEY_RIGHT),
|
||||
KEY(4, 4, KEY_LEFTCTRL),
|
||||
KEY(4, 5, KEY_RIGHTALT),
|
||||
KEY(4, 6, KEY_LEFTSHIFT),
|
||||
KEY(4, 8, KEY_F10),
|
||||
|
||||
KEY(5, 0, KEY_Y),
|
||||
KEY(5, 8, KEY_F11),
|
||||
|
||||
KEY(6, 0, KEY_U),
|
||||
|
||||
KEY(7, 0, KEY_I),
|
||||
KEY(7, 1, KEY_F7),
|
||||
KEY(7, 2, KEY_F8),
|
||||
KEY(0xff, 2, KEY_F9),
|
||||
KEY(0xff, 4, KEY_F10),
|
||||
KEY(0xff, 5, KEY_F11),
|
||||
};
|
||||
|
||||
static struct matrix_keymap_data board_map_data = {
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
#define _COLIBRI_H_
|
||||
|
||||
#include <net/ax88796.h>
|
||||
#include <mach/mfp.h>
|
||||
|
||||
/*
|
||||
* common settings for all modules
|
||||
|
|
|
|||
|
|
@ -18,6 +18,7 @@ config REALVIEW_EB_ARM11MP
|
|||
bool "Support ARM11MPCore tile"
|
||||
depends on MACH_REALVIEW_EB
|
||||
select CPU_V6
|
||||
select ARCH_HAS_BARRIERS if SMP
|
||||
help
|
||||
Enable support for the ARM11MPCore tile on the Realview platform.
|
||||
|
||||
|
|
@ -35,6 +36,7 @@ config MACH_REALVIEW_PB11MP
|
|||
select CPU_V6
|
||||
select ARM_GIC
|
||||
select HAVE_PATA_PLATFORM
|
||||
select ARCH_HAS_BARRIERS if SMP
|
||||
help
|
||||
Include support for the ARM(R) RealView MPCore Platform Baseboard.
|
||||
PB11MPCore is a platform with an on-board ARM11MPCore and has
|
||||
|
|
|
|||
8
arch/arm/mach-realview/include/mach/barriers.h
Normal file
8
arch/arm/mach-realview/include/mach/barriers.h
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
/*
|
||||
* Barriers redefined for RealView ARM11MPCore platforms with L220 cache
|
||||
* controller to work around hardware errata causing the outer_sync()
|
||||
* operation to deadlock the system.
|
||||
*/
|
||||
#define mb() dsb()
|
||||
#define rmb() dmb()
|
||||
#define wmb() mb()
|
||||
|
|
@ -60,14 +60,20 @@
|
|||
#define PMEM_GPU_SIZE SZ_64M
|
||||
#define PMEM_UI_SIZE SZ_32M
|
||||
#define PMEM_VPU_SIZE SZ_32M
|
||||
#define PMEM_CAM_SIZE SZ_16M
|
||||
#define PMEM_CAM_SIZE 0x00c00000
|
||||
#ifdef CONFIG_VIDEO_RK29_WORK_IPP
|
||||
#define MEM_CAMIPP_SIZE SZ_4M
|
||||
#else
|
||||
#define MEM_CAMIPP_SIZE 0
|
||||
#endif
|
||||
#define MEM_FB_SIZE (3*SZ_2M)
|
||||
|
||||
#define PMEM_GPU_BASE ((u32)RK29_SDRAM_PHYS + SDRAM_SIZE - PMEM_GPU_SIZE)
|
||||
#define PMEM_UI_BASE (PMEM_GPU_BASE - PMEM_UI_SIZE)
|
||||
#define PMEM_VPU_BASE (PMEM_UI_BASE - PMEM_VPU_SIZE)
|
||||
#define PMEM_CAM_BASE (PMEM_VPU_BASE - PMEM_CAM_SIZE)
|
||||
#define MEM_FB_BASE (PMEM_CAM_BASE - MEM_FB_SIZE)
|
||||
#define MEM_CAMIPP_BASE (PMEM_CAM_BASE - MEM_CAMIPP_SIZE)
|
||||
#define MEM_FB_BASE (MEM_CAMIPP_BASE - MEM_FB_SIZE)
|
||||
#define LINUX_SIZE (MEM_FB_BASE - RK29_SDRAM_PHYS)
|
||||
|
||||
extern struct sys_timer rk29_timer;
|
||||
|
|
@ -577,7 +583,14 @@ struct rk29camera_platform_data rk29_camera_platform_data = {
|
|||
.gpio_flag = (SENSOR_POWERACTIVE_LEVEL_1|SENSOR_RESETACTIVE_LEVEL_1),
|
||||
.dev_name = SENSOR_NAME_1,
|
||||
}
|
||||
}
|
||||
},
|
||||
#ifdef CONFIG_VIDEO_RK29_WORK_IPP
|
||||
.meminfo = {
|
||||
.name = "camera_ipp_mem",
|
||||
.start = MEM_CAMIPP_BASE,
|
||||
.size = MEM_CAMIPP_SIZE,
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static int rk29_sensor_io_init(void)
|
||||
|
|
@ -737,7 +750,32 @@ struct platform_device rk29_soc_camera_pdrv_1 = {
|
|||
};
|
||||
|
||||
|
||||
extern struct platform_device rk29_device_camera;
|
||||
static u64 rockchip_device_camera_dmamask = 0xffffffffUL;
|
||||
struct resource rk29_camera_resource[] = {
|
||||
[0] = {
|
||||
.start = RK29_VIP_PHYS,
|
||||
.end = RK29_VIP_PHYS + RK29_VIP_SIZE - 1,
|
||||
.flags = IORESOURCE_MEM,
|
||||
},
|
||||
[1] = {
|
||||
.start = IRQ_VIP,
|
||||
.end = IRQ_VIP,
|
||||
.flags = IORESOURCE_IRQ,
|
||||
}
|
||||
};
|
||||
|
||||
/*platform_device : */
|
||||
struct platform_device rk29_device_camera = {
|
||||
.name = RK29_CAM_DRV_NAME,
|
||||
.id = RK29_CAM_PLATFORM_DEV_ID, /* This is used to put cameras on this interface */
|
||||
.num_resources = ARRAY_SIZE(rk29_camera_resource),
|
||||
.resource = rk29_camera_resource,
|
||||
.dev = {
|
||||
.dma_mask = &rockchip_device_camera_dmamask,
|
||||
.coherent_dma_mask = 0xffffffffUL,
|
||||
.platform_data = &rk29_camera_platform_data,
|
||||
}
|
||||
};
|
||||
#endif
|
||||
/*****************************************************************************************
|
||||
* backlight devices
|
||||
|
|
@ -1032,13 +1070,6 @@ static struct platform_device rk29_device_keys = {
|
|||
},
|
||||
};
|
||||
#endif
|
||||
/********************usb*********************/
|
||||
struct usb_mass_storage_platform_data mass_storage_pdata = {
|
||||
.nluns = 1,
|
||||
.vendor = "RockChip",
|
||||
.product = "rk9 sdk",
|
||||
.release = 0x0100,
|
||||
};
|
||||
|
||||
static void __init rk29_board_iomux_init(void)
|
||||
{
|
||||
|
|
@ -1171,13 +1202,22 @@ static struct platform_device *devices[] __initdata = {
|
|||
#endif
|
||||
&android_pmem_device,
|
||||
&rk29_vpu_mem_device,
|
||||
#ifdef CONFIG_DWC_OTG
|
||||
&rk29_device_dwc_otg,
|
||||
#ifdef CONFIG_USB20_OTG
|
||||
&rk29_device_usb20_otg,
|
||||
#endif
|
||||
#ifdef CONFIG_USB20_HOST
|
||||
&rk29_device_usb20_host,
|
||||
#endif
|
||||
#ifdef CONFIG_USB11_HOST
|
||||
&rk29_device_usb11_host,
|
||||
#endif
|
||||
#ifdef CONFIG_USB_ANDROID
|
||||
&android_usb_device,
|
||||
&usb_mass_storage_device,
|
||||
#endif
|
||||
#ifdef CONFIG_RK29_IPP
|
||||
&rk29_device_ipp,
|
||||
#endif
|
||||
};
|
||||
|
||||
/*****************************************************************************************
|
||||
|
|
|
|||
|
|
@ -31,6 +31,13 @@
|
|||
#include <mach/rk29_iomap.h>
|
||||
#include <mach/cru.h>
|
||||
|
||||
|
||||
#define PWM_VCORE_120 40
|
||||
#define PWM_VCORE_125 32
|
||||
#define PWM_VCORE_130 21
|
||||
#define PWM_VCORE_135 10
|
||||
#define PWM_VCORE_140 0
|
||||
|
||||
/* CRU PLL CON */
|
||||
#define PLL_HIGH_BAND (0x01 << 16)
|
||||
#define PLL_LOW_BAND (0x00 << 16)
|
||||
|
|
@ -360,11 +367,11 @@ static const struct arm_pll_set arm_pll[] = {
|
|||
ARM_PLL(1152, 1, 48, 1, 41, 21, 81),
|
||||
ARM_PLL(1104, 1, 46, 1, 41, 21, 81),
|
||||
ARM_PLL(1056, 1, 44, 1, 41, 21, 81),
|
||||
ARM_PLL(1008, 1, 42, 1, 31, 21, 81),
|
||||
ARM_PLL( 960, 1, 40, 1, 31, 21, 81),
|
||||
ARM_PLL( 912, 1, 38, 1, 31, 21, 81),
|
||||
ARM_PLL(1008, 1, 42, 1, 41, 21, 81),
|
||||
ARM_PLL( 960, 1, 40, 1, 41, 21, 81),
|
||||
ARM_PLL( 912, 1, 38, 1, 41, 21, 81),
|
||||
ARM_PLL( 888, 2, 74, 1, 31, 21, 81),
|
||||
ARM_PLL( 624, 1, 52, 2, 21, 21, 81),
|
||||
ARM_PLL( 624, 1, 52, 2, 31, 21, 81),
|
||||
// last item, pll power down.
|
||||
ARM_PLL( 24, 1, 64, 8, 21, 21, 41),
|
||||
};
|
||||
|
|
@ -462,7 +469,7 @@ static int arm_pll_clk_set_rate(struct clk *clk, unsigned long rate)
|
|||
pt++;
|
||||
}
|
||||
|
||||
PWMInit(1 * MHZ, 0); // 1.4V
|
||||
PWMInit(1 * MHZ, PWM_VCORE_135); // 1.35V
|
||||
|
||||
/* make aclk safe & reparent to periph pll */
|
||||
cru_writel((cru_readl(CRU_CLKSEL0_CON) & ~(CORE_PARENT_MASK | CORE_ACLK_MASK)) | CORE_PARENT_PERIPH_PLL | CORE_ACLK_21, CRU_CLKSEL0_CON);
|
||||
|
|
@ -2257,9 +2264,9 @@ static void rk29_clock_common_init(void)
|
|||
/* periph pll */
|
||||
clk_set_rate_nolock(&periph_pll_clk, 624 * MHZ);
|
||||
clk_set_parent_nolock(&aclk_periph, &periph_pll_clk);
|
||||
clk_set_rate_nolock(&aclk_periph, 312 * MHZ);
|
||||
clk_set_rate_nolock(&hclk_periph, 156 * MHZ);
|
||||
clk_set_rate_nolock(&pclk_periph, 78 * MHZ);
|
||||
clk_set_rate_nolock(&aclk_periph, 208 * MHZ);
|
||||
clk_set_rate_nolock(&hclk_periph, 104 * MHZ);
|
||||
clk_set_rate_nolock(&pclk_periph, 52 * MHZ);
|
||||
clk_set_parent_nolock(&clk_uhost, &periph_pll_clk);
|
||||
clk_set_rate_nolock(&clk_uhost, 48 * MHZ);
|
||||
clk_set_parent_nolock(&clk_i2s0_div, &periph_pll_clk);
|
||||
|
|
|
|||
|
|
@ -404,39 +404,6 @@ struct platform_device rk29xx_device_spi1m = {
|
|||
},
|
||||
};
|
||||
|
||||
/* RK29 Camera : ddl@rock-chips.com */
|
||||
#ifdef CONFIG_VIDEO_RK29
|
||||
extern struct rk29camera_platform_data rk29_camera_platform_data;
|
||||
|
||||
static struct resource rk29_camera_resource[] = {
|
||||
[0] = {
|
||||
.start = RK29_VIP_PHYS,
|
||||
.end = RK29_VIP_PHYS + RK29_VIP_SIZE - 1,
|
||||
.flags = IORESOURCE_MEM,
|
||||
},
|
||||
[1] = {
|
||||
.start = IRQ_VIP,
|
||||
.end = IRQ_VIP,
|
||||
.flags = IORESOURCE_IRQ,
|
||||
}
|
||||
};
|
||||
|
||||
static u64 rockchip_device_camera_dmamask = 0xffffffffUL;
|
||||
|
||||
/*platform_device : */
|
||||
struct platform_device rk29_device_camera = {
|
||||
.name = RK29_CAM_DRV_NAME,
|
||||
.id = RK29_CAM_PLATFORM_DEV_ID, /* This is used to put cameras on this interface */
|
||||
.num_resources = ARRAY_SIZE(rk29_camera_resource),
|
||||
.resource = rk29_camera_resource,
|
||||
.dev = {
|
||||
.dma_mask = &rockchip_device_camera_dmamask,
|
||||
.coherent_dma_mask = 0xffffffffUL,
|
||||
.platform_data = &rk29_camera_platform_data,
|
||||
}
|
||||
};
|
||||
#endif
|
||||
|
||||
#if defined(CONFIG_MTD_NAND_RK29XX)
|
||||
static struct resource rk29xxnand_resources[] = {
|
||||
{
|
||||
|
|
@ -541,9 +508,34 @@ struct platform_device rk29_device_iis_8ch = {
|
|||
.resource = rk29_iis_8ch_resource,
|
||||
};
|
||||
#endif
|
||||
#ifdef CONFIG_DWC_OTG
|
||||
#ifdef CONFIG_RK29_IPP
|
||||
/* rk29 ipp resource */
|
||||
static struct resource rk29_ipp_resource[] = {
|
||||
[0] = {
|
||||
.start = RK29_IPP_PHYS,
|
||||
.end = RK29_IPP_PHYS + RK29_IPP_SIZE - 1,
|
||||
.flags = IORESOURCE_MEM,
|
||||
},
|
||||
[1] = {
|
||||
.start = IRQ_IPP,
|
||||
.end = IRQ_IPP,
|
||||
.flags = IORESOURCE_IRQ,
|
||||
},
|
||||
};
|
||||
|
||||
/*platform_device*/
|
||||
//extern struct rk29ipp_info rk29_ipp_info;
|
||||
struct platform_device rk29_device_ipp = {
|
||||
.name = "rk29-ipp",
|
||||
.id = -1,
|
||||
.num_resources = ARRAY_SIZE(rk29_ipp_resource),
|
||||
.resource = rk29_ipp_resource,
|
||||
};
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_USB20_OTG
|
||||
/*DWC_OTG*/
|
||||
static struct resource dwc_otg_resource[] = {
|
||||
static struct resource usb20_otg_resource[] = {
|
||||
{
|
||||
.start = IRQ_USB_OTG0,
|
||||
.end = IRQ_USB_OTG0,
|
||||
|
|
@ -557,12 +549,14 @@ static struct resource dwc_otg_resource[] = {
|
|||
|
||||
};
|
||||
|
||||
struct platform_device rk29_device_dwc_otg = {
|
||||
.name = "dwc_otg",
|
||||
struct platform_device rk29_device_usb20_otg = {
|
||||
.name = "usb20_otg",
|
||||
.id = -1,
|
||||
.num_resources = ARRAY_SIZE(dwc_otg_resource),
|
||||
.resource = dwc_otg_resource,
|
||||
.num_resources = ARRAY_SIZE(usb20_otg_resource),
|
||||
.resource = usb20_otg_resource,
|
||||
};
|
||||
#endif
|
||||
#ifdef CONFIG_USB_ANDROID
|
||||
|
||||
static char *usb_functions_rockchip[] = {
|
||||
"usb_mass_storage",
|
||||
|
|
@ -615,7 +609,7 @@ static struct android_usb_product usb_products[] = {
|
|||
.functions = usb_functions_rockchip,
|
||||
},
|
||||
{
|
||||
.product_id = 0x4e12,
|
||||
.product_id = 0x2810,//0x0c02,//0x4e12,
|
||||
.num_functions = ARRAY_SIZE(usb_functions_rockchip_adb),
|
||||
.functions = usb_functions_rockchip_adb,
|
||||
},
|
||||
|
|
@ -637,7 +631,10 @@ static struct android_usb_product usb_products[] = {
|
|||
},
|
||||
#endif
|
||||
};
|
||||
|
||||
/*
|
||||
* if anyone want to use adb driver of HTC G1,
|
||||
* please change vendor_id to 0x0bb4 and product_id to 0x0c02.
|
||||
*/
|
||||
static struct android_usb_platform_data android_usb_pdata = {
|
||||
.vendor_id = 0x2207,//0x0bb4,//0x18d1,
|
||||
.product_id = 0x2810,//0x4e11,
|
||||
|
|
@ -659,6 +656,14 @@ struct platform_device android_usb_device = {
|
|||
},
|
||||
};
|
||||
|
||||
/********************usb*********************/
|
||||
struct usb_mass_storage_platform_data mass_storage_pdata = {
|
||||
.nluns = 1,
|
||||
.vendor = "RockChip",
|
||||
.product = "rk29 sdk",
|
||||
.release = 0x0100,
|
||||
};
|
||||
|
||||
//static
|
||||
struct platform_device usb_mass_storage_device = {
|
||||
.name = "usb_mass_storage",
|
||||
|
|
@ -668,3 +673,48 @@ struct platform_device usb_mass_storage_device = {
|
|||
},
|
||||
};
|
||||
#endif
|
||||
#ifdef CONFIG_USB11_HOST
|
||||
static struct resource usb11_host_resource[] = {
|
||||
{
|
||||
.start = IRQ_USB_HOST,
|
||||
.end = IRQ_USB_HOST,
|
||||
.flags = IORESOURCE_IRQ,
|
||||
},
|
||||
{
|
||||
.start = RK29_USBHOST_PHYS,
|
||||
.end = RK29_USBHOST_PHYS + RK29_USBHOST_SIZE - 1,
|
||||
.flags = IORESOURCE_MEM,
|
||||
},
|
||||
|
||||
};
|
||||
|
||||
struct platform_device rk29_device_usb11_host = {
|
||||
.name = "usb11_host",
|
||||
.id = -1,
|
||||
.num_resources = ARRAY_SIZE(usb11_host_resource),
|
||||
.resource = usb11_host_resource,
|
||||
};
|
||||
#endif
|
||||
#ifdef CONFIG_USB20_HOST
|
||||
static struct resource usb20_host_resource[] = {
|
||||
{
|
||||
.start = IRQ_USB_OTG1,
|
||||
.end = IRQ_USB_OTG1,
|
||||
.flags = IORESOURCE_IRQ,
|
||||
},
|
||||
{
|
||||
.start = RK29_USBOTG1_PHYS,
|
||||
.end = RK29_USBOTG1_PHYS + RK29_USBOTG1_SIZE - 1,
|
||||
.flags = IORESOURCE_MEM,
|
||||
},
|
||||
|
||||
};
|
||||
|
||||
struct platform_device rk29_device_usb20_host = {
|
||||
.name = "usb20_host",
|
||||
.id = -1,
|
||||
.num_resources = ARRAY_SIZE(usb20_host_resource),
|
||||
.resource = usb20_host_resource,
|
||||
};
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -50,10 +50,13 @@ extern struct platform_device rk29_device_adc;
|
|||
extern struct platform_device rk29_device_vmac;
|
||||
extern struct rk29_bl_info rk29_bl_info;
|
||||
extern struct platform_device rk29_device_backlight;
|
||||
extern struct platform_device rk29_device_dwc_otg;
|
||||
extern struct platform_device rk29_device_usb20_otg;
|
||||
extern struct platform_device rk29_device_usb20_host;
|
||||
extern struct platform_device rk29_device_usb11_host;
|
||||
extern struct platform_device android_usb_device;
|
||||
extern struct usb_mass_storage_platform_data mass_storage_pdata;
|
||||
extern struct platform_device usb_mass_storage_device;
|
||||
extern struct platform_device rk29_device_vmac;
|
||||
extern struct rk29_vmac_platform_data rk29_vmac_pdata;
|
||||
extern struct platform_device rk29_device_ipp;
|
||||
#endif
|
||||
|
|
|
|||
103
arch/arm/mach-rk29/include/mach/rk29-ipp.h
Normal file
103
arch/arm/mach-rk29/include/mach/rk29-ipp.h
Normal file
|
|
@ -0,0 +1,103 @@
|
|||
#ifndef _RK29_IPP_DRIVER_H_
|
||||
#define _RK29_IPP_DRIVER_H_
|
||||
|
||||
/* Image data */
|
||||
struct rk29_ipp_image
|
||||
{
|
||||
uint32_t YrgbMst; // image Y/rgb address
|
||||
uint32_t CbrMst; // image CbCr address
|
||||
uint32_t w; // image full width
|
||||
uint32_t h; // image full height
|
||||
uint32_t fmt; // color format
|
||||
};
|
||||
|
||||
struct rk29_ipp_req {
|
||||
struct rk29_ipp_image src0; // source0 image
|
||||
struct rk29_ipp_image dst0; // destination0 image
|
||||
struct rk29_ipp_image src1; // source1 image
|
||||
struct rk29_ipp_image dst1; // destination1 image
|
||||
uint32_t src_vir_w;
|
||||
uint32_t dst_vir_w;
|
||||
uint32_t timeout;
|
||||
uint32_t flag; //rotate
|
||||
};
|
||||
|
||||
//uint32_t format ö¾ÙÀàÐÍ
|
||||
enum
|
||||
{
|
||||
IPP_XRGB_8888 = 0,
|
||||
IPP_RGB_565 =1 ,
|
||||
IPP_Y_CBCR_H2V1 = 2, //yuv 422sp
|
||||
IPP_Y_CBCR_H2V2 = 3, //yuv 420sp
|
||||
IPP_Y_CBCR_H1V1 =6, //yuv 444sp
|
||||
IPP_IMGTYPE_LIMIT
|
||||
};
|
||||
|
||||
typedef enum
|
||||
{
|
||||
IPP_ROT_90,
|
||||
IPP_ROT_180,
|
||||
IPP_ROT_270,
|
||||
IPP_ROT_X_FLIP,
|
||||
IPP_ROT_Y_FLIP,
|
||||
IPP_ROT_0,
|
||||
IPP_ROT_LIMIT
|
||||
} ROT_DEG;
|
||||
|
||||
struct ipp_regs {
|
||||
uint32_t ipp_config;
|
||||
uint32_t ipp_src_img_info;
|
||||
uint32_t ipp_dst_img_info;
|
||||
uint32_t ipp_img_vir;
|
||||
uint32_t ipp_int;
|
||||
uint32_t ipp_src0_y_mst;
|
||||
uint32_t ipp_src0_Cbr_mst;
|
||||
uint32_t ipp_src1_y_mst;
|
||||
uint32_t ipp_src1_Cbr_mst;
|
||||
uint32_t ipp_dst0_y_mst;
|
||||
uint32_t ipp_dst0_Cbr_mst;
|
||||
uint32_t ipp_dst1_y_mst;
|
||||
uint32_t ipp_dst1_Cbr_mst;
|
||||
uint32_t ipp_pre_scl_para;
|
||||
uint32_t ipp_post_scl_para;
|
||||
uint32_t ipp_swap_ctrl;
|
||||
uint32_t ipp_pre_img_info;
|
||||
uint32_t ipp_axi_id;
|
||||
uint32_t ipp_process_st;
|
||||
};
|
||||
|
||||
#define IPP_CONFIG (0x00)
|
||||
#define IPP_SRC_IMG_INFO (0x04)
|
||||
#define IPP_DST_IMG_INFO (0x08)
|
||||
#define IPP_IMG_VIR (0x0c)
|
||||
#define IPP_INT (0x10)
|
||||
#define IPP_SRC0_Y_MST (0x14)
|
||||
#define IPP_SRC0_CBR_MST (0x18)
|
||||
#define IPP_SRC1_Y_MST (0x1c)
|
||||
#define IPP_SRC1_CBR_MST (0x20)
|
||||
#define IPP_DST0_Y_MST (0x24)
|
||||
#define IPP_DST0_CBR_MST (0x28)
|
||||
#define IPP_DST1_Y_MST (0x2c)
|
||||
#define IPP_DST1_CBR_MST (0x30)
|
||||
#define IPP_PRE_SCL_PARA (0x34)
|
||||
#define IPP_POST_SCL_PARA (0x38)
|
||||
#define IPP_SWAP_CTRL (0x3c)
|
||||
#define IPP_PRE_IMG_INFO (0x40)
|
||||
#define IPP_AXI_ID (0x44)
|
||||
#define IPP_SRESET (0x48)
|
||||
#define IPP_PROCESS_ST (0x50)
|
||||
|
||||
/*ipp config*/
|
||||
#define ROT_ENABLE (1<<8)
|
||||
#define PRE_SCALE (1<<4)
|
||||
#define POST_SCALE (1<<3)
|
||||
|
||||
|
||||
#define IS_YCRCB(img) ((img == IPP_Y_CBCR_H2V1) | (img == IPP_Y_CBCR_H2V2) | \
|
||||
(img == IPP_Y_CBCR_H1V1) )
|
||||
#define IS_RGB(img) ((img == IPP_RGB_565) | (img == IPP_ARGB_8888) | \
|
||||
(img == IPP_XRGB_8888) ))
|
||||
#define HAS_ALPHA(img) (img == IPP_ARGB_8888)
|
||||
|
||||
int ipp_do_blit(struct rk29_ipp_req *req);
|
||||
#endif /*_RK29_IPP_DRIVER_H_*/
|
||||
6
arch/arm/mach-rk29/include/mach/rk29_camera.h
Executable file → Normal file
6
arch/arm/mach-rk29/include/mach/rk29_camera.h
Executable file → Normal file
|
|
@ -53,10 +53,16 @@ struct rk29camera_gpio_res {
|
|||
const char *dev_name;
|
||||
};
|
||||
|
||||
struct rk29camera_mem_res {
|
||||
const char *name;
|
||||
unsigned int start;
|
||||
unsigned int size;
|
||||
};
|
||||
struct rk29camera_platform_data {
|
||||
int (*io_init)(void);
|
||||
int (*io_deinit)(void);
|
||||
struct rk29camera_gpio_res gpio_res[2];
|
||||
struct rk29camera_mem_res meminfo;
|
||||
};
|
||||
|
||||
#endif /* __ASM_ARCH_CAMERA_H_ */
|
||||
|
|
|
|||
|
|
@ -82,26 +82,28 @@ typedef volatile struct tagCHIP_IF
|
|||
}CHIP_IF, *pCHIP_IF;
|
||||
|
||||
//NANDC Registers
|
||||
typedef volatile struct tagNANDC
|
||||
typedef volatile struct tagNANDC
|
||||
{
|
||||
volatile uint32_t FMCTL;
|
||||
volatile uint32_t FMWAIT;
|
||||
volatile uint32_t FLCTL;
|
||||
volatile uint32_t BCHCTL;
|
||||
volatile uint32_t BCHST;
|
||||
volatile uint32_t RESERVED1[(0x200-0x14)/4]; //FLR
|
||||
volatile uint32_t MTRANS_CFG;
|
||||
volatile uint32_t MTRANS_SADDR0;
|
||||
volatile uint32_t MTRANS_SADDR1;
|
||||
volatile uint32_t MTRANS_STAT;
|
||||
|
||||
volatile uint32_t BCHST[8];
|
||||
volatile uint32_t FLR1[(0x160-0x40)/4];
|
||||
volatile uint32_t NANDC_VER;
|
||||
volatile uint32_t FLR2[(0x200-0x164)/4];
|
||||
volatile uint32_t spare[0x200/4];
|
||||
volatile uint32_t FMCTL1;
|
||||
volatile uint32_t FMWAIT1;
|
||||
volatile uint32_t FLCTL1;
|
||||
volatile uint32_t BCHCTL1;
|
||||
volatile uint32_t BCHST1;
|
||||
volatile uint32_t RESERVED2[(0x200-0x14)/4];
|
||||
volatile uint32_t RESERVED3[0x200/4];
|
||||
volatile uint32_t RESERVED2[0x400/4];
|
||||
volatile CHIP_IF chip[8];
|
||||
volatile uint32_t buf[0x800/4];
|
||||
}NANDC, *pNANDC;
|
||||
|
||||
|
||||
struct rk29_nand_flash {
|
||||
const struct rk29_nand_timing *timing; /* NAND Flash timing */
|
||||
const struct rk29_nand_cmdset *cmdset;
|
||||
|
|
|
|||
|
|
@ -252,11 +252,11 @@ static int region_check(int index)
|
|||
}
|
||||
|
||||
/*
|
||||
* split allocated block from free block
|
||||
* split new allocated block from free block
|
||||
* the bitmap_sem and region_list_sem must be hold together
|
||||
* the pnode is a ouput region node
|
||||
*/
|
||||
static int region_split(struct list_head *region_list, struct vpu_mem_region_node *node, int index, int pfn)
|
||||
static int region_new(struct list_head *region_list, int index, int pfn)
|
||||
{
|
||||
int pfn_free = VPU_MEM_PFN(index);
|
||||
// check pfn is smaller then target index region
|
||||
|
|
@ -274,8 +274,9 @@ static int region_split(struct list_head *region_list, struct vpu_mem_region_nod
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (NULL == node) {
|
||||
{
|
||||
struct list_head *last;
|
||||
struct vpu_mem_region_node *node;
|
||||
// check target index region first
|
||||
if (!VPU_MEM_IS_FREE(index)) {
|
||||
#if VPU_MEM_DEBUG
|
||||
|
|
@ -310,12 +311,58 @@ static int region_split(struct list_head *region_list, struct vpu_mem_region_nod
|
|||
|
||||
region_set_avail(index, VPU_MEM_AVAIL(index) + 1);
|
||||
region_set_ref_count(index, VPU_MEM_REFC(index) + 1);
|
||||
node->region.index = index;
|
||||
node->region.ref_count = 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* link allocated block from free block
|
||||
* the bitmap_sem and region_list_sem must be hold together
|
||||
* the pnode is a ouput region node
|
||||
*/
|
||||
static int region_link(struct list_head *region_list, int index)
|
||||
{
|
||||
struct vpu_mem_region_node *node = NULL;
|
||||
struct list_head *list, *tmp;
|
||||
list_for_each_safe(list, tmp, region_list) {
|
||||
struct vpu_mem_region_node *p = list_entry(list, struct vpu_mem_region_node, list);
|
||||
if (index == NODE_REGION_INDEX(p)) {
|
||||
node = p;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (NULL == node) {
|
||||
struct list_head *last;
|
||||
DLOG("link non-exists index %d\n", index);
|
||||
|
||||
// malloc vpu_mem_region_node
|
||||
node = kmalloc(sizeof(struct vpu_mem_region_node), GFP_KERNEL);
|
||||
if (NULL == node) {
|
||||
#if VPU_MEM_DEBUG
|
||||
printk(KERN_INFO "No space to allocate struct vpu_mem_region_node!");
|
||||
#endif
|
||||
return -ENOMEM;
|
||||
}
|
||||
|
||||
// search the last node
|
||||
DLOG("search the last node\n");
|
||||
for (last = region_list; !list_is_last(last, region_list);)
|
||||
last = last->next;
|
||||
|
||||
DLOG("list_add_tail\n");
|
||||
list_add_tail(&node->list, last);
|
||||
|
||||
node->region.index = index;
|
||||
node->region.ref_count = 1;
|
||||
} else {
|
||||
region_set_ref_count(index, VPU_MEM_REFC(index) + 1);
|
||||
DLOG("link existed index %d\n", index);
|
||||
node->region.ref_count++;
|
||||
}
|
||||
region_set_ref_count(index, VPU_MEM_REFC(index) + 1);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -391,11 +438,11 @@ static long vpu_mem_allocate(struct file *file, unsigned int len)
|
|||
}
|
||||
}
|
||||
#if VPU_MEM_DEBUG
|
||||
printk(KERN_INFO "vpu_mem: search curr %d\n!", curr);
|
||||
//printk(KERN_INFO "vpu_mem: search curr %d\n!", curr);
|
||||
#endif
|
||||
curr = VPU_MEM_NEXT_INDEX(curr);
|
||||
#if VPU_MEM_DEBUG
|
||||
printk(KERN_INFO "vpu_mem: search next %d\n!", curr);
|
||||
//printk(KERN_INFO "vpu_mem: search next %d\n!", curr);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
@ -413,7 +460,7 @@ static long vpu_mem_allocate(struct file *file, unsigned int len)
|
|||
|
||||
down_write(&data->sem);
|
||||
{
|
||||
int ret = region_split(&data->region_list, NULL, best_fit, pfn);
|
||||
int ret = region_new(&data->region_list, best_fit, pfn);
|
||||
if (ret)
|
||||
best_fit = -1;
|
||||
}
|
||||
|
|
@ -518,6 +565,7 @@ static int vpu_mem_duplicate(struct file *file, int index)
|
|||
|
||||
static int vpu_mem_link(struct file *file, int index)
|
||||
{
|
||||
int err;
|
||||
struct vpu_mem_data *data = (struct vpu_mem_data *)file->private_data;
|
||||
|
||||
if (!is_vpu_mem_file(file)) {
|
||||
|
|
@ -534,26 +582,21 @@ static int vpu_mem_link(struct file *file, int index)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
// check target index region first
|
||||
if (VPU_MEM_IS_FREE(index)) {
|
||||
#if VPU_MEM_DEBUG
|
||||
printk(KERN_INFO "try to link free region %d!", index);
|
||||
#endif
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* caller should hold the write lock on vpu_mem_sem! */
|
||||
DLOG("link index %d\n", index);
|
||||
|
||||
down_write(&data->sem);
|
||||
{ // search exists index
|
||||
struct list_head *list, *tmp;
|
||||
list_for_each_safe(list, tmp, &data->region_list) {
|
||||
struct vpu_mem_region_node *node = list_entry(list, struct vpu_mem_region_node, list);
|
||||
if (index == NODE_REGION_INDEX(node)) {
|
||||
region_split(&data->region_list, node, index, VPU_MEM_PFN(index));
|
||||
up_write(&data->sem);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
// non-exists index
|
||||
region_split(&data->region_list, NULL, index, VPU_MEM_PFN(index));
|
||||
}
|
||||
err = region_link(&data->region_list, index);
|
||||
up_write(&data->sem);
|
||||
DLOG("link index %d ret %d\n", index, err);
|
||||
|
||||
return 0;
|
||||
return err;
|
||||
}
|
||||
|
||||
void vpu_mem_flush(struct file *file, long index)
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ feroceon_copy_user_page(void *kto, const void *kfrom)
|
|||
{
|
||||
asm("\
|
||||
stmfd sp!, {r4-r9, lr} \n\
|
||||
mov ip, %0 \n\
|
||||
mov ip, %2 \n\
|
||||
1: mov lr, r1 \n\
|
||||
ldmia r1!, {r2 - r9} \n\
|
||||
pld [lr, #32] \n\
|
||||
|
|
@ -64,7 +64,7 @@ feroceon_copy_user_page(void *kto, const void *kfrom)
|
|||
mcr p15, 0, ip, c7, c10, 4 @ drain WB\n\
|
||||
ldmfd sp!, {r4-r9, pc}"
|
||||
:
|
||||
: "I" (PAGE_SIZE));
|
||||
: "r" (kto), "r" (kfrom), "I" (PAGE_SIZE));
|
||||
}
|
||||
|
||||
void feroceon_copy_user_highpage(struct page *to, struct page *from,
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ v4wb_copy_user_page(void *kto, const void *kfrom)
|
|||
{
|
||||
asm("\
|
||||
stmfd sp!, {r4, lr} @ 2\n\
|
||||
mov r2, %0 @ 1\n\
|
||||
mov r2, %2 @ 1\n\
|
||||
ldmia r1!, {r3, r4, ip, lr} @ 4\n\
|
||||
1: mcr p15, 0, r0, c7, c6, 1 @ 1 invalidate D line\n\
|
||||
stmia r0!, {r3, r4, ip, lr} @ 4\n\
|
||||
|
|
@ -44,7 +44,7 @@ v4wb_copy_user_page(void *kto, const void *kfrom)
|
|||
mcr p15, 0, r1, c7, c10, 4 @ 1 drain WB\n\
|
||||
ldmfd sp!, {r4, pc} @ 3"
|
||||
:
|
||||
: "I" (PAGE_SIZE / 64));
|
||||
: "r" (kto), "r" (kfrom), "I" (PAGE_SIZE / 64));
|
||||
}
|
||||
|
||||
void v4wb_copy_user_highpage(struct page *to, struct page *from,
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ v4wt_copy_user_page(void *kto, const void *kfrom)
|
|||
{
|
||||
asm("\
|
||||
stmfd sp!, {r4, lr} @ 2\n\
|
||||
mov r2, %0 @ 1\n\
|
||||
mov r2, %2 @ 1\n\
|
||||
ldmia r1!, {r3, r4, ip, lr} @ 4\n\
|
||||
1: stmia r0!, {r3, r4, ip, lr} @ 4\n\
|
||||
ldmia r1!, {r3, r4, ip, lr} @ 4+1\n\
|
||||
|
|
@ -40,7 +40,7 @@ v4wt_copy_user_page(void *kto, const void *kfrom)
|
|||
mcr p15, 0, r2, c7, c7, 0 @ flush ID cache\n\
|
||||
ldmfd sp!, {r4, pc} @ 3"
|
||||
:
|
||||
: "I" (PAGE_SIZE / 64));
|
||||
: "r" (kto), "r" (kfrom), "I" (PAGE_SIZE / 64));
|
||||
}
|
||||
|
||||
void v4wt_copy_user_highpage(struct page *to, struct page *from,
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ xsc3_mc_copy_user_page(void *kto, const void *kfrom)
|
|||
{
|
||||
asm("\
|
||||
stmfd sp!, {r4, r5, lr} \n\
|
||||
mov lr, %0 \n\
|
||||
mov lr, %2 \n\
|
||||
\n\
|
||||
pld [r1, #0] \n\
|
||||
pld [r1, #32] \n\
|
||||
|
|
@ -67,7 +67,7 @@ xsc3_mc_copy_user_page(void *kto, const void *kfrom)
|
|||
\n\
|
||||
ldmfd sp!, {r4, r5, pc}"
|
||||
:
|
||||
: "I" (PAGE_SIZE / 64 - 1));
|
||||
: "r" (kto), "r" (kfrom), "I" (PAGE_SIZE / 64 - 1));
|
||||
}
|
||||
|
||||
void xsc3_mc_copy_user_highpage(struct page *to, struct page *from,
|
||||
|
|
|
|||
|
|
@ -386,6 +386,9 @@ do_translation_fault(unsigned long addr, unsigned int fsr,
|
|||
if (addr < TASK_SIZE)
|
||||
return do_page_fault(addr, fsr, regs);
|
||||
|
||||
if (user_mode(regs))
|
||||
goto bad_area;
|
||||
|
||||
index = pgd_index(addr);
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -272,7 +272,7 @@ __v7_setup:
|
|||
bic r5, r5, #7 << 6
|
||||
bic r5, r5, #15
|
||||
orr r5, r5, #3 << 6 @ Tag RAM latency: b011 = 4 cycles
|
||||
orr r5, r5, #5 @ Data RAM latency: b0101 = 6 cycles
|
||||
orr r5, r5, #12 @ Data RAM latency: b0101 = 6 cycles
|
||||
mcr p15, 1, r5, c9, c0, 2
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -223,13 +223,16 @@ static void _set_gpio_direction(struct gpio_chip *chip, unsigned offset,
|
|||
struct mxc_gpio_port *port =
|
||||
container_of(chip, struct mxc_gpio_port, chip);
|
||||
u32 l;
|
||||
unsigned long flags;
|
||||
|
||||
spin_lock_irqsave(&port->lock, flags);
|
||||
l = __raw_readl(port->base + GPIO_GDIR);
|
||||
if (dir)
|
||||
l |= 1 << offset;
|
||||
else
|
||||
l &= ~(1 << offset);
|
||||
__raw_writel(l, port->base + GPIO_GDIR);
|
||||
spin_unlock_irqrestore(&port->lock, flags);
|
||||
}
|
||||
|
||||
static void mxc_gpio_set(struct gpio_chip *chip, unsigned offset, int value)
|
||||
|
|
@ -238,9 +241,12 @@ static void mxc_gpio_set(struct gpio_chip *chip, unsigned offset, int value)
|
|||
container_of(chip, struct mxc_gpio_port, chip);
|
||||
void __iomem *reg = port->base + GPIO_DR;
|
||||
u32 l;
|
||||
unsigned long flags;
|
||||
|
||||
spin_lock_irqsave(&port->lock, flags);
|
||||
l = (__raw_readl(reg) & (~(1 << offset))) | (value << offset);
|
||||
__raw_writel(l, reg);
|
||||
spin_unlock_irqrestore(&port->lock, flags);
|
||||
}
|
||||
|
||||
static int mxc_gpio_get(struct gpio_chip *chip, unsigned offset)
|
||||
|
|
@ -294,6 +300,8 @@ int __init mxc_gpio_init(struct mxc_gpio_port *port, int cnt)
|
|||
port[i].chip.base = i * 32;
|
||||
port[i].chip.ngpio = 32;
|
||||
|
||||
spin_lock_init(&port[i].lock);
|
||||
|
||||
/* its a serious configuration bug when it fails */
|
||||
BUG_ON( gpiochip_add(&port[i].chip) < 0 );
|
||||
|
||||
|
|
|
|||
|
|
@ -19,6 +19,7 @@
|
|||
#ifndef __ASM_ARCH_MXC_GPIO_H__
|
||||
#define __ASM_ARCH_MXC_GPIO_H__
|
||||
|
||||
#include <linux/spinlock.h>
|
||||
#include <mach/hardware.h>
|
||||
#include <asm-generic/gpio.h>
|
||||
|
||||
|
|
@ -36,6 +37,7 @@ struct mxc_gpio_port {
|
|||
int virtual_irq_start;
|
||||
struct gpio_chip chip;
|
||||
u32 both_edges;
|
||||
spinlock_t lock;
|
||||
};
|
||||
|
||||
int mxc_gpio_init(struct mxc_gpio_port*, int);
|
||||
|
|
|
|||
|
|
@ -277,7 +277,7 @@ ENTRY(vfp_put_double)
|
|||
#ifdef CONFIG_VFPv3
|
||||
@ d16 - d31 registers
|
||||
.irp dr,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15
|
||||
1: mcrr p11, 3, r1, r2, c\dr @ fmdrr r1, r2, d\dr
|
||||
1: mcrr p11, 3, r0, r1, c\dr @ fmdrr r0, r1, d\dr
|
||||
mov pc, lr
|
||||
.org 1b + 8
|
||||
.endr
|
||||
|
|
|
|||
|
|
@ -15,6 +15,8 @@
|
|||
#define L1_CACHE_BYTES (1 << L1_CACHE_SHIFT)
|
||||
#define SMP_CACHE_BYTES L1_CACHE_BYTES
|
||||
|
||||
#define ARCH_KMALLOC_MINALIGN L1_CACHE_BYTES
|
||||
|
||||
#ifdef CONFIG_SMP
|
||||
#define __cacheline_aligned
|
||||
#else
|
||||
|
|
|
|||
|
|
@ -17,6 +17,8 @@
|
|||
#define L1_CACHE_SHIFT (CONFIG_FRV_L1_CACHE_SHIFT)
|
||||
#define L1_CACHE_BYTES (1 << L1_CACHE_SHIFT)
|
||||
|
||||
#define ARCH_KMALLOC_MINALIGN L1_CACHE_BYTES
|
||||
|
||||
#define __cacheline_aligned __attribute__((aligned(L1_CACHE_BYTES)))
|
||||
#define ____cacheline_aligned __attribute__((aligned(L1_CACHE_BYTES)))
|
||||
|
||||
|
|
|
|||
|
|
@ -677,12 +677,19 @@ sba_alloc_range(struct ioc *ioc, struct device *dev, size_t size)
|
|||
spin_unlock_irqrestore(&ioc->saved_lock, flags);
|
||||
|
||||
pide = sba_search_bitmap(ioc, dev, pages_needed, 0);
|
||||
if (unlikely(pide >= (ioc->res_size << 3)))
|
||||
panic(__FILE__ ": I/O MMU @ %p is out of mapping resources\n",
|
||||
ioc->ioc_hpa);
|
||||
if (unlikely(pide >= (ioc->res_size << 3))) {
|
||||
printk(KERN_WARNING "%s: I/O MMU @ %p is"
|
||||
"out of mapping resources, %u %u %lx\n",
|
||||
__func__, ioc->ioc_hpa, ioc->res_size,
|
||||
pages_needed, dma_get_seg_boundary(dev));
|
||||
return -1;
|
||||
}
|
||||
#else
|
||||
panic(__FILE__ ": I/O MMU @ %p is out of mapping resources\n",
|
||||
ioc->ioc_hpa);
|
||||
printk(KERN_WARNING "%s: I/O MMU @ %p is"
|
||||
"out of mapping resources, %u %u %lx\n",
|
||||
__func__, ioc->ioc_hpa, ioc->res_size,
|
||||
pages_needed, dma_get_seg_boundary(dev));
|
||||
return -1;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
|
@ -965,6 +972,8 @@ static dma_addr_t sba_map_page(struct device *dev, struct page *page,
|
|||
#endif
|
||||
|
||||
pide = sba_alloc_range(ioc, dev, size);
|
||||
if (pide < 0)
|
||||
return 0;
|
||||
|
||||
iovp = (dma_addr_t) pide << iovp_shift;
|
||||
|
||||
|
|
@ -1320,6 +1329,7 @@ sba_coalesce_chunks(struct ioc *ioc, struct device *dev,
|
|||
unsigned long dma_offset, dma_len; /* start/len of DMA stream */
|
||||
int n_mappings = 0;
|
||||
unsigned int max_seg_size = dma_get_max_seg_size(dev);
|
||||
int idx;
|
||||
|
||||
while (nents > 0) {
|
||||
unsigned long vaddr = (unsigned long) sba_sg_address(startsg);
|
||||
|
|
@ -1418,16 +1428,22 @@ sba_coalesce_chunks(struct ioc *ioc, struct device *dev,
|
|||
vcontig_sg->dma_length = vcontig_len;
|
||||
dma_len = (dma_len + dma_offset + ~iovp_mask) & iovp_mask;
|
||||
ASSERT(dma_len <= DMA_CHUNK_SIZE);
|
||||
dma_sg->dma_address = (dma_addr_t) (PIDE_FLAG
|
||||
| (sba_alloc_range(ioc, dev, dma_len) << iovp_shift)
|
||||
| dma_offset);
|
||||
idx = sba_alloc_range(ioc, dev, dma_len);
|
||||
if (idx < 0) {
|
||||
dma_sg->dma_length = 0;
|
||||
return -1;
|
||||
}
|
||||
dma_sg->dma_address = (dma_addr_t)(PIDE_FLAG | (idx << iovp_shift)
|
||||
| dma_offset);
|
||||
n_mappings++;
|
||||
}
|
||||
|
||||
return n_mappings;
|
||||
}
|
||||
|
||||
|
||||
static void sba_unmap_sg_attrs(struct device *dev, struct scatterlist *sglist,
|
||||
int nents, enum dma_data_direction dir,
|
||||
struct dma_attrs *attrs);
|
||||
/**
|
||||
* sba_map_sg - map Scatter/Gather list
|
||||
* @dev: instance of PCI owned by the driver that's asking.
|
||||
|
|
@ -1493,6 +1509,10 @@ static int sba_map_sg_attrs(struct device *dev, struct scatterlist *sglist,
|
|||
** Access to the virtual address is what forces a two pass algorithm.
|
||||
*/
|
||||
coalesced = sba_coalesce_chunks(ioc, dev, sglist, nents);
|
||||
if (coalesced < 0) {
|
||||
sba_unmap_sg_attrs(dev, sglist, nents, dir, attrs);
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
** Program the I/O Pdir
|
||||
|
|
|
|||
|
|
@ -94,6 +94,7 @@ ia64_acpi_release_global_lock (unsigned int *lock)
|
|||
#define acpi_noirq 0 /* ACPI always enabled on IA64 */
|
||||
#define acpi_pci_disabled 0 /* ACPI PCI always enabled on IA64 */
|
||||
#define acpi_strict 1 /* no ACPI spec workarounds on IA64 */
|
||||
#define acpi_ht 0 /* no HT-only mode on IA64 */
|
||||
#endif
|
||||
#define acpi_processor_cstate_check(x) (x) /* no idle limits on IA64 :) */
|
||||
static inline void disable_acpi(void) { }
|
||||
|
|
|
|||
|
|
@ -198,7 +198,7 @@ ptr_to_compat(void __user *uptr)
|
|||
}
|
||||
|
||||
static __inline__ void __user *
|
||||
compat_alloc_user_space (long len)
|
||||
arch_compat_alloc_user_space (long len)
|
||||
{
|
||||
struct pt_regs *regs = task_pt_regs(current);
|
||||
return (void __user *) (((regs->r12 & 0xffffffff) & -16) - len);
|
||||
|
|
|
|||
|
|
@ -420,22 +420,31 @@ EX(.fail_efault, ld8 r14=[r33]) // r14 <- *set
|
|||
;;
|
||||
|
||||
RSM_PSR_I(p0, r18, r19) // mask interrupt delivery
|
||||
mov ar.ccv=0
|
||||
andcm r14=r14,r17 // filter out SIGKILL & SIGSTOP
|
||||
mov r8=EINVAL // default to EINVAL
|
||||
|
||||
#ifdef CONFIG_SMP
|
||||
mov r17=1
|
||||
// __ticket_spin_trylock(r31)
|
||||
ld4 r17=[r31]
|
||||
;;
|
||||
cmpxchg4.acq r18=[r31],r17,ar.ccv // try to acquire the lock
|
||||
mov r8=EINVAL // default to EINVAL
|
||||
mov.m ar.ccv=r17
|
||||
extr.u r9=r17,17,15
|
||||
adds r19=1,r17
|
||||
extr.u r18=r17,0,15
|
||||
;;
|
||||
cmp.eq p6,p7=r9,r18
|
||||
;;
|
||||
(p6) cmpxchg4.acq r9=[r31],r19,ar.ccv
|
||||
(p6) dep.z r20=r19,1,15 // next serving ticket for unlock
|
||||
(p7) br.cond.spnt.many .lock_contention
|
||||
;;
|
||||
cmp4.eq p0,p7=r9,r17
|
||||
adds r31=2,r31
|
||||
(p7) br.cond.spnt.many .lock_contention
|
||||
ld8 r3=[r2] // re-read current->blocked now that we hold the lock
|
||||
cmp4.ne p6,p0=r18,r0
|
||||
(p6) br.cond.spnt.many .lock_contention
|
||||
;;
|
||||
#else
|
||||
ld8 r3=[r2] // re-read current->blocked now that we hold the lock
|
||||
mov r8=EINVAL // default to EINVAL
|
||||
#endif
|
||||
add r18=IA64_TASK_PENDING_OFFSET+IA64_SIGPENDING_SIGNAL_OFFSET,r16
|
||||
add r19=IA64_TASK_SIGNAL_OFFSET,r16
|
||||
|
|
@ -490,7 +499,9 @@ EX(.fail_efault, ld8 r14=[r33]) // r14 <- *set
|
|||
(p6) br.cond.spnt.few 1b // yes -> retry
|
||||
|
||||
#ifdef CONFIG_SMP
|
||||
st4.rel [r31]=r0 // release the lock
|
||||
// __ticket_spin_unlock(r31)
|
||||
st2.rel [r31]=r20
|
||||
mov r20=0 // i must not leak kernel bits...
|
||||
#endif
|
||||
SSM_PSR_I(p0, p9, r31)
|
||||
;;
|
||||
|
|
@ -512,7 +523,8 @@ EX(.fail_efault, (p15) st8 [r34]=r3)
|
|||
|
||||
.sig_pending:
|
||||
#ifdef CONFIG_SMP
|
||||
st4.rel [r31]=r0 // release the lock
|
||||
// __ticket_spin_unlock(r31)
|
||||
st2.rel [r31]=r20 // release the lock
|
||||
#endif
|
||||
SSM_PSR_I(p0, p9, r17)
|
||||
;;
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ static int ia64_set_msi_irq_affinity(unsigned int irq,
|
|||
if (irq_prepare_move(irq, cpu))
|
||||
return -1;
|
||||
|
||||
read_msi_msg(irq, &msg);
|
||||
get_cached_msi_msg(irq, &msg);
|
||||
|
||||
addr = msg.address_lo;
|
||||
addr &= MSI_ADDR_DEST_ID_MASK;
|
||||
|
|
|
|||
|
|
@ -473,7 +473,7 @@ void update_vsyscall_tz(void)
|
|||
{
|
||||
}
|
||||
|
||||
void update_vsyscall(struct timespec *wall, struct clocksource *c)
|
||||
void update_vsyscall(struct timespec *wall, struct clocksource *c, u32 mult)
|
||||
{
|
||||
unsigned long flags;
|
||||
|
||||
|
|
@ -481,7 +481,7 @@ void update_vsyscall(struct timespec *wall, struct clocksource *c)
|
|||
|
||||
/* copy fsyscall clock data */
|
||||
fsyscall_gtod_data.clk_mask = c->mask;
|
||||
fsyscall_gtod_data.clk_mult = c->mult;
|
||||
fsyscall_gtod_data.clk_mult = mult;
|
||||
fsyscall_gtod_data.clk_shift = c->shift;
|
||||
fsyscall_gtod_data.clk_fsys_mmio = c->fsys_mmio;
|
||||
fsyscall_gtod_data.clk_cycle_last = c->cycle_last;
|
||||
|
|
|
|||
|
|
@ -1797,7 +1797,8 @@ static int kvm_ia64_sync_dirty_log(struct kvm *kvm,
|
|||
{
|
||||
struct kvm_memory_slot *memslot;
|
||||
int r, i;
|
||||
long n, base;
|
||||
long base;
|
||||
unsigned long n;
|
||||
unsigned long *dirty_bitmap = (unsigned long *)(kvm->arch.vm_base +
|
||||
offsetof(struct kvm_vm_data, kvm_mem_dirty_log));
|
||||
|
||||
|
|
@ -1810,7 +1811,7 @@ static int kvm_ia64_sync_dirty_log(struct kvm *kvm,
|
|||
if (!memslot->dirty_bitmap)
|
||||
goto out;
|
||||
|
||||
n = ALIGN(memslot->npages, BITS_PER_LONG) / 8;
|
||||
n = kvm_dirty_bitmap_bytes(memslot);
|
||||
base = memslot->base_gfn / BITS_PER_LONG;
|
||||
|
||||
for (i = 0; i < n/sizeof(long); ++i) {
|
||||
|
|
@ -1826,7 +1827,7 @@ int kvm_vm_ioctl_get_dirty_log(struct kvm *kvm,
|
|||
struct kvm_dirty_log *log)
|
||||
{
|
||||
int r;
|
||||
int n;
|
||||
unsigned long n;
|
||||
struct kvm_memory_slot *memslot;
|
||||
int is_dirty = 0;
|
||||
|
||||
|
|
@ -1844,7 +1845,7 @@ int kvm_vm_ioctl_get_dirty_log(struct kvm *kvm,
|
|||
if (is_dirty) {
|
||||
kvm_flush_remote_tlbs(kvm);
|
||||
memslot = &kvm->memslots[log->slot];
|
||||
n = ALIGN(memslot->npages, BITS_PER_LONG) / 8;
|
||||
n = kvm_dirty_bitmap_bytes(memslot);
|
||||
memset(memslot->dirty_bitmap, 0, n);
|
||||
}
|
||||
r = 0;
|
||||
|
|
|
|||
|
|
@ -120,7 +120,7 @@ static inline void down_spin(struct spinaphore *ss)
|
|||
ia64_invala();
|
||||
|
||||
for (;;) {
|
||||
asm volatile ("ld4.c.nc %0=[%1]" : "=r"(serve) : "r"(&ss->serve) : "memory");
|
||||
asm volatile ("ld8.c.nc %0=[%1]" : "=r"(serve) : "r"(&ss->serve) : "memory");
|
||||
if (time_before(t, serve))
|
||||
return;
|
||||
cpu_relax();
|
||||
|
|
|
|||
|
|
@ -174,7 +174,7 @@ static int sn_set_msi_irq_affinity(unsigned int irq,
|
|||
* Release XIO resources for the old MSI PCI address
|
||||
*/
|
||||
|
||||
read_msi_msg(irq, &msg);
|
||||
get_cached_msi_msg(irq, &msg);
|
||||
sn_pdev = (struct pcidev_info *)sn_irq_info->irq_pciioinfo;
|
||||
pdev = sn_pdev->pdi_linux_pcidev;
|
||||
provider = SN_PCIDEV_BUSPROVIDER(pdev);
|
||||
|
|
|
|||
|
|
@ -8,4 +8,6 @@
|
|||
#define L1_CACHE_SHIFT 4
|
||||
#define L1_CACHE_BYTES (1<< L1_CACHE_SHIFT)
|
||||
|
||||
#define ARCH_KMALLOC_MINALIGN L1_CACHE_BYTES
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -69,12 +69,16 @@ export MMU DTB
|
|||
|
||||
all: linux.bin
|
||||
|
||||
BOOT_TARGETS = linux.bin linux.bin.gz simpleImage.%
|
||||
# With make 3.82 we cannot mix normal and wildcard targets
|
||||
BOOT_TARGETS1 = linux.bin linux.bin.gz
|
||||
BOOT_TARGETS2 = simpleImage.%
|
||||
|
||||
archclean:
|
||||
$(Q)$(MAKE) $(clean)=$(boot)
|
||||
|
||||
$(BOOT_TARGETS): vmlinux
|
||||
$(BOOT_TARGETS1): vmlinux
|
||||
$(Q)$(MAKE) $(build)=$(boot) $(boot)/$@
|
||||
$(BOOT_TARGETS2): vmlinux
|
||||
$(Q)$(MAKE) $(build)=$(boot) $(boot)/$@
|
||||
|
||||
define archhelp
|
||||
|
|
|
|||
|
|
@ -434,7 +434,7 @@ static __inline__ void atomic64_add(long i, atomic64_t * v)
|
|||
__asm__ __volatile__(
|
||||
" .set mips3 \n"
|
||||
"1: lld %0, %1 # atomic64_add \n"
|
||||
" addu %0, %2 \n"
|
||||
" daddu %0, %2 \n"
|
||||
" scd %0, %1 \n"
|
||||
" beqzl %0, 1b \n"
|
||||
" .set mips0 \n"
|
||||
|
|
@ -446,7 +446,7 @@ static __inline__ void atomic64_add(long i, atomic64_t * v)
|
|||
__asm__ __volatile__(
|
||||
" .set mips3 \n"
|
||||
"1: lld %0, %1 # atomic64_add \n"
|
||||
" addu %0, %2 \n"
|
||||
" daddu %0, %2 \n"
|
||||
" scd %0, %1 \n"
|
||||
" beqz %0, 2f \n"
|
||||
" .subsection 2 \n"
|
||||
|
|
@ -479,7 +479,7 @@ static __inline__ void atomic64_sub(long i, atomic64_t * v)
|
|||
__asm__ __volatile__(
|
||||
" .set mips3 \n"
|
||||
"1: lld %0, %1 # atomic64_sub \n"
|
||||
" subu %0, %2 \n"
|
||||
" dsubu %0, %2 \n"
|
||||
" scd %0, %1 \n"
|
||||
" beqzl %0, 1b \n"
|
||||
" .set mips0 \n"
|
||||
|
|
@ -491,7 +491,7 @@ static __inline__ void atomic64_sub(long i, atomic64_t * v)
|
|||
__asm__ __volatile__(
|
||||
" .set mips3 \n"
|
||||
"1: lld %0, %1 # atomic64_sub \n"
|
||||
" subu %0, %2 \n"
|
||||
" dsubu %0, %2 \n"
|
||||
" scd %0, %1 \n"
|
||||
" beqz %0, 2f \n"
|
||||
" .subsection 2 \n"
|
||||
|
|
@ -524,10 +524,10 @@ static __inline__ long atomic64_add_return(long i, atomic64_t * v)
|
|||
__asm__ __volatile__(
|
||||
" .set mips3 \n"
|
||||
"1: lld %1, %2 # atomic64_add_return \n"
|
||||
" addu %0, %1, %3 \n"
|
||||
" daddu %0, %1, %3 \n"
|
||||
" scd %0, %2 \n"
|
||||
" beqzl %0, 1b \n"
|
||||
" addu %0, %1, %3 \n"
|
||||
" daddu %0, %1, %3 \n"
|
||||
" .set mips0 \n"
|
||||
: "=&r" (result), "=&r" (temp), "=m" (v->counter)
|
||||
: "Ir" (i), "m" (v->counter)
|
||||
|
|
@ -538,10 +538,10 @@ static __inline__ long atomic64_add_return(long i, atomic64_t * v)
|
|||
__asm__ __volatile__(
|
||||
" .set mips3 \n"
|
||||
"1: lld %1, %2 # atomic64_add_return \n"
|
||||
" addu %0, %1, %3 \n"
|
||||
" daddu %0, %1, %3 \n"
|
||||
" scd %0, %2 \n"
|
||||
" beqz %0, 2f \n"
|
||||
" addu %0, %1, %3 \n"
|
||||
" daddu %0, %1, %3 \n"
|
||||
" .subsection 2 \n"
|
||||
"2: b 1b \n"
|
||||
" .previous \n"
|
||||
|
|
@ -576,10 +576,10 @@ static __inline__ long atomic64_sub_return(long i, atomic64_t * v)
|
|||
__asm__ __volatile__(
|
||||
" .set mips3 \n"
|
||||
"1: lld %1, %2 # atomic64_sub_return \n"
|
||||
" subu %0, %1, %3 \n"
|
||||
" dsubu %0, %1, %3 \n"
|
||||
" scd %0, %2 \n"
|
||||
" beqzl %0, 1b \n"
|
||||
" subu %0, %1, %3 \n"
|
||||
" dsubu %0, %1, %3 \n"
|
||||
" .set mips0 \n"
|
||||
: "=&r" (result), "=&r" (temp), "=m" (v->counter)
|
||||
: "Ir" (i), "m" (v->counter)
|
||||
|
|
@ -590,10 +590,10 @@ static __inline__ long atomic64_sub_return(long i, atomic64_t * v)
|
|||
__asm__ __volatile__(
|
||||
" .set mips3 \n"
|
||||
"1: lld %1, %2 # atomic64_sub_return \n"
|
||||
" subu %0, %1, %3 \n"
|
||||
" dsubu %0, %1, %3 \n"
|
||||
" scd %0, %2 \n"
|
||||
" beqz %0, 2f \n"
|
||||
" subu %0, %1, %3 \n"
|
||||
" dsubu %0, %1, %3 \n"
|
||||
" .subsection 2 \n"
|
||||
"2: b 1b \n"
|
||||
" .previous \n"
|
||||
|
|
|
|||
|
|
@ -144,7 +144,7 @@ static inline compat_uptr_t ptr_to_compat(void __user *uptr)
|
|||
return (u32)(unsigned long)uptr;
|
||||
}
|
||||
|
||||
static inline void __user *compat_alloc_user_space(long len)
|
||||
static inline void __user *arch_compat_alloc_user_space(long len)
|
||||
{
|
||||
struct pt_regs *regs = (struct pt_regs *)
|
||||
((unsigned long) current_thread_info() + THREAD_SIZE - 32) - 1;
|
||||
|
|
|
|||
|
|
@ -16,7 +16,11 @@
|
|||
#if defined(CONFIG_SB1_PASS_1_WORKAROUNDS) || \
|
||||
defined(CONFIG_SB1_PASS_2_WORKAROUNDS)
|
||||
|
||||
#define BCM1250_M3_WAR 1
|
||||
#ifndef __ASSEMBLY__
|
||||
extern int sb1250_m3_workaround_needed(void);
|
||||
#endif
|
||||
|
||||
#define BCM1250_M3_WAR sb1250_m3_workaround_needed()
|
||||
#define SIBYTE_1956_WAR 1
|
||||
|
||||
#else
|
||||
|
|
|
|||
|
|
@ -134,6 +134,12 @@
|
|||
#define FPU_CSR_COND6 0x40000000 /* $fcc6 */
|
||||
#define FPU_CSR_COND7 0x80000000 /* $fcc7 */
|
||||
|
||||
/*
|
||||
* Bits 18 - 20 of the FPU Status Register will be read as 0,
|
||||
* and should be written as zero.
|
||||
*/
|
||||
#define FPU_CSR_RSVD 0x001c0000
|
||||
|
||||
/*
|
||||
* X the exception cause indicator
|
||||
* E the exception enable
|
||||
|
|
@ -161,7 +167,8 @@
|
|||
#define FPU_CSR_UDF_S 0x00000008
|
||||
#define FPU_CSR_INE_S 0x00000004
|
||||
|
||||
/* rounding mode */
|
||||
/* Bits 0 and 1 of FPU Status Register specify the rounding mode */
|
||||
#define FPU_CSR_RM 0x00000003
|
||||
#define FPU_CSR_RN 0x0 /* nearest */
|
||||
#define FPU_CSR_RZ 0x1 /* towards zero */
|
||||
#define FPU_CSR_RU 0x2 /* towards +Infinity */
|
||||
|
|
|
|||
|
|
@ -75,6 +75,9 @@ struct mips_fpu_emulator_stats fpuemustats;
|
|||
#define FPCREG_RID 0 /* $0 = revision id */
|
||||
#define FPCREG_CSR 31 /* $31 = csr */
|
||||
|
||||
/* Determine rounding mode from the RM bits of the FCSR */
|
||||
#define modeindex(v) ((v) & FPU_CSR_RM)
|
||||
|
||||
/* Convert Mips rounding mode (0..3) to IEEE library modes. */
|
||||
static const unsigned char ieee_rm[4] = {
|
||||
[FPU_CSR_RN] = IEEE754_RN,
|
||||
|
|
@ -381,10 +384,14 @@ static int cop1Emulate(struct pt_regs *xcp, struct mips_fpu_struct *ctx)
|
|||
(void *) (xcp->cp0_epc),
|
||||
MIPSInst_RT(ir), value);
|
||||
#endif
|
||||
value &= (FPU_CSR_FLUSH | FPU_CSR_ALL_E | FPU_CSR_ALL_S | 0x03);
|
||||
ctx->fcr31 &= ~(FPU_CSR_FLUSH | FPU_CSR_ALL_E | FPU_CSR_ALL_S | 0x03);
|
||||
/* convert to ieee library modes */
|
||||
ctx->fcr31 |= (value & ~0x3) | ieee_rm[value & 0x3];
|
||||
|
||||
/*
|
||||
* Don't write reserved bits,
|
||||
* and convert to ieee library modes
|
||||
*/
|
||||
ctx->fcr31 = (value &
|
||||
~(FPU_CSR_RSVD | FPU_CSR_RM)) |
|
||||
ieee_rm[modeindex(value)];
|
||||
}
|
||||
if ((ctx->fcr31 >> 5) & ctx->fcr31 & FPU_CSR_ALL_E) {
|
||||
return SIGFPE;
|
||||
|
|
|
|||
|
|
@ -73,9 +73,6 @@ static int __cpuinit m4kc_tlbp_war(void)
|
|||
enum label_id {
|
||||
label_second_part = 1,
|
||||
label_leave,
|
||||
#ifdef MODULE_START
|
||||
label_module_alloc,
|
||||
#endif
|
||||
label_vmalloc,
|
||||
label_vmalloc_done,
|
||||
label_tlbw_hazard,
|
||||
|
|
@ -92,9 +89,6 @@ enum label_id {
|
|||
|
||||
UASM_L_LA(_second_part)
|
||||
UASM_L_LA(_leave)
|
||||
#ifdef MODULE_START
|
||||
UASM_L_LA(_module_alloc)
|
||||
#endif
|
||||
UASM_L_LA(_vmalloc)
|
||||
UASM_L_LA(_vmalloc_done)
|
||||
UASM_L_LA(_tlbw_hazard)
|
||||
|
|
@ -731,10 +725,15 @@ static void __cpuinit build_r4000_tlb_refill_handler(void)
|
|||
* create the plain linear handler
|
||||
*/
|
||||
if (bcm1250_m3_war()) {
|
||||
UASM_i_MFC0(&p, K0, C0_BADVADDR);
|
||||
UASM_i_MFC0(&p, K1, C0_ENTRYHI);
|
||||
unsigned int segbits = 44;
|
||||
|
||||
uasm_i_dmfc0(&p, K0, C0_BADVADDR);
|
||||
uasm_i_dmfc0(&p, K1, C0_ENTRYHI);
|
||||
uasm_i_xor(&p, K0, K0, K1);
|
||||
UASM_i_SRL(&p, K0, K0, PAGE_SHIFT + 1);
|
||||
uasm_i_dsrl32(&p, K1, K0, 62 - 32);
|
||||
uasm_i_dsrl(&p, K0, K0, 12 + 1);
|
||||
uasm_i_dsll32(&p, K0, K0, 64 + 12 + 1 - segbits - 32);
|
||||
uasm_i_or(&p, K0, K0, K1);
|
||||
uasm_il_bnez(&p, &r, K0, label_leave);
|
||||
/* No need for uasm_i_nop */
|
||||
}
|
||||
|
|
@ -802,8 +801,6 @@ static void __cpuinit build_r4000_tlb_refill_handler(void)
|
|||
} else {
|
||||
#if defined(CONFIG_HUGETLB_PAGE)
|
||||
const enum label_id ls = label_tlb_huge_update;
|
||||
#elif defined(MODULE_START)
|
||||
const enum label_id ls = label_module_alloc;
|
||||
#else
|
||||
const enum label_id ls = label_vmalloc;
|
||||
#endif
|
||||
|
|
@ -1250,10 +1247,15 @@ static void __cpuinit build_r4000_tlb_load_handler(void)
|
|||
memset(relocs, 0, sizeof(relocs));
|
||||
|
||||
if (bcm1250_m3_war()) {
|
||||
UASM_i_MFC0(&p, K0, C0_BADVADDR);
|
||||
UASM_i_MFC0(&p, K1, C0_ENTRYHI);
|
||||
unsigned int segbits = 44;
|
||||
|
||||
uasm_i_dmfc0(&p, K0, C0_BADVADDR);
|
||||
uasm_i_dmfc0(&p, K1, C0_ENTRYHI);
|
||||
uasm_i_xor(&p, K0, K0, K1);
|
||||
UASM_i_SRL(&p, K0, K0, PAGE_SHIFT + 1);
|
||||
uasm_i_dsrl32(&p, K1, K0, 62 - 32);
|
||||
uasm_i_dsrl(&p, K0, K0, 12 + 1);
|
||||
uasm_i_dsll32(&p, K0, K0, 64 + 12 + 1 - segbits - 32);
|
||||
uasm_i_or(&p, K0, K0, K1);
|
||||
uasm_il_bnez(&p, &r, K0, label_leave);
|
||||
/* No need for uasm_i_nop */
|
||||
}
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ enum opcode {
|
|||
insn_dmtc0, insn_dsll, insn_dsll32, insn_dsra, insn_dsrl,
|
||||
insn_dsrl32, insn_dsubu, insn_eret, insn_j, insn_jal, insn_jr,
|
||||
insn_ld, insn_ll, insn_lld, insn_lui, insn_lw, insn_mfc0,
|
||||
insn_mtc0, insn_ori, insn_pref, insn_rfe, insn_sc, insn_scd,
|
||||
insn_mtc0, insn_or, insn_ori, insn_pref, insn_rfe, insn_sc, insn_scd,
|
||||
insn_sd, insn_sll, insn_sra, insn_srl, insn_subu, insn_sw,
|
||||
insn_tlbp, insn_tlbwi, insn_tlbwr, insn_xor, insn_xori
|
||||
};
|
||||
|
|
@ -116,6 +116,7 @@ static struct insn insn_table[] __cpuinitdata = {
|
|||
{ insn_lw, M(lw_op, 0, 0, 0, 0, 0), RS | RT | SIMM },
|
||||
{ insn_mfc0, M(cop0_op, mfc_op, 0, 0, 0, 0), RT | RD | SET},
|
||||
{ insn_mtc0, M(cop0_op, mtc_op, 0, 0, 0, 0), RT | RD | SET},
|
||||
{ insn_or, M(spec_op, 0, 0, 0, 0, or_op), RS | RT | RD },
|
||||
{ insn_ori, M(ori_op, 0, 0, 0, 0, 0), RS | RT | UIMM },
|
||||
{ insn_pref, M(pref_op, 0, 0, 0, 0, 0), RS | RT | SIMM },
|
||||
{ insn_rfe, M(cop0_op, cop_op, 0, 0, 0, rfe_op), 0 },
|
||||
|
|
@ -362,6 +363,7 @@ I_u2s3u1(_lw)
|
|||
I_u1u2u3(_mfc0)
|
||||
I_u1u2u3(_mtc0)
|
||||
I_u2u1u3(_ori)
|
||||
I_u3u1u2(_or)
|
||||
I_u2s3u1(_pref)
|
||||
I_0(_rfe)
|
||||
I_u2s3u1(_sc)
|
||||
|
|
|
|||
|
|
@ -78,6 +78,7 @@ Ip_u2s3u1(_lw);
|
|||
Ip_u1u2u3(_mfc0);
|
||||
Ip_u1u2u3(_mtc0);
|
||||
Ip_u2u1u3(_ori);
|
||||
Ip_u3u1u2(_or);
|
||||
Ip_u2s3u1(_pref);
|
||||
Ip_0(_rfe);
|
||||
Ip_u2s3u1(_sc);
|
||||
|
|
|
|||
|
|
@ -247,6 +247,8 @@ void __init mips_pcibios_init(void)
|
|||
iomem_resource.end &= 0xfffffffffULL; /* 64 GB */
|
||||
ioport_resource.end = controller->io_resource->end;
|
||||
|
||||
controller->io_map_base = mips_io_port_base;
|
||||
|
||||
register_pci_controller(controller);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -44,6 +44,7 @@ extern struct pci_ops pnx8550_pci_ops;
|
|||
|
||||
static struct pci_controller pnx8550_controller = {
|
||||
.pci_ops = &pnx8550_pci_ops,
|
||||
.io_map_base = PNX8550_PORT_BASE,
|
||||
.io_resource = &pci_io_resource,
|
||||
.mem_resource = &pci_mem_resource,
|
||||
};
|
||||
|
|
|
|||
|
|
@ -113,7 +113,7 @@ void __init plat_mem_setup(void)
|
|||
PNX8550_GLB2_ENAB_INTA_O = 0;
|
||||
|
||||
/* IO/MEM resources. */
|
||||
set_io_port_base(KSEG1);
|
||||
set_io_port_base(PNX8550_PORT_BASE);
|
||||
ioport_resource.start = 0;
|
||||
ioport_resource.end = ~0;
|
||||
iomem_resource.start = 0;
|
||||
|
|
|
|||
|
|
@ -944,6 +944,7 @@ static struct pci_controller msp_pci_controller = {
|
|||
.pci_ops = &msp_pci_ops,
|
||||
.mem_resource = &pci_mem_resource,
|
||||
.mem_offset = 0,
|
||||
.io_map_base = MSP_PCI_IOSPACE_BASE,
|
||||
.io_resource = &pci_io_resource,
|
||||
.io_offset = 0
|
||||
};
|
||||
|
|
|
|||
|
|
@ -54,6 +54,7 @@ static int __init pmc_yosemite_setup(void)
|
|||
panic(ioremap_failed);
|
||||
|
||||
set_io_port_base(io_v_base);
|
||||
py_controller.io_map_base = io_v_base;
|
||||
TITAN_WRITE(RM9000x2_OCD_LKM7, TITAN_READ(RM9000x2_OCD_LKM7) | 1);
|
||||
|
||||
ioport_resource.end = TITAN_IO_SIZE - 1;
|
||||
|
|
|
|||
|
|
@ -87,6 +87,21 @@ static int __init setup_bcm1250(void)
|
|||
return ret;
|
||||
}
|
||||
|
||||
int sb1250_m3_workaround_needed(void)
|
||||
{
|
||||
switch (soc_type) {
|
||||
case K_SYS_SOC_TYPE_BCM1250:
|
||||
case K_SYS_SOC_TYPE_BCM1250_ALT:
|
||||
case K_SYS_SOC_TYPE_BCM1250_ALT2:
|
||||
case K_SYS_SOC_TYPE_BCM1125:
|
||||
case K_SYS_SOC_TYPE_BCM1125H:
|
||||
return soc_pass < K_SYS_REVISION_BCM1250_C0;
|
||||
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
static int __init setup_bcm112x(void)
|
||||
{
|
||||
int ret = 0;
|
||||
|
|
|
|||
|
|
@ -21,6 +21,8 @@
|
|||
#define L1_CACHE_DISPARITY L1_CACHE_NENTRIES * L1_CACHE_BYTES
|
||||
#endif
|
||||
|
||||
#define ARCH_KMALLOC_MINALIGN L1_CACHE_BYTES
|
||||
|
||||
/* data cache purge registers
|
||||
* - read from the register to unconditionally purge that cache line
|
||||
* - write address & 0xffffff00 to conditionally purge that cache line
|
||||
|
|
|
|||
|
|
@ -146,7 +146,7 @@ static inline compat_uptr_t ptr_to_compat(void __user *uptr)
|
|||
return (u32)(unsigned long)uptr;
|
||||
}
|
||||
|
||||
static __inline__ void __user *compat_alloc_user_space(long len)
|
||||
static __inline__ void __user *arch_compat_alloc_user_space(long len)
|
||||
{
|
||||
struct pt_regs *regs = ¤t->thread.regs;
|
||||
return (void __user *)regs->gr[30];
|
||||
|
|
|
|||
|
|
@ -1123,7 +1123,6 @@ static char __attribute__((aligned(64))) iodc_dbuf[4096];
|
|||
*/
|
||||
int pdc_iodc_print(const unsigned char *str, unsigned count)
|
||||
{
|
||||
static int posx; /* for simple TAB-Simulation... */
|
||||
unsigned int i;
|
||||
unsigned long flags;
|
||||
|
||||
|
|
@ -1133,19 +1132,12 @@ int pdc_iodc_print(const unsigned char *str, unsigned count)
|
|||
iodc_dbuf[i+0] = '\r';
|
||||
iodc_dbuf[i+1] = '\n';
|
||||
i += 2;
|
||||
posx = 0;
|
||||
goto print;
|
||||
case '\t':
|
||||
while (posx & 7) {
|
||||
iodc_dbuf[i] = ' ';
|
||||
i++, posx++;
|
||||
}
|
||||
break;
|
||||
case '\b': /* BS */
|
||||
posx -= 2;
|
||||
i--; /* overwrite last */
|
||||
default:
|
||||
iodc_dbuf[i] = str[i];
|
||||
i++, posx++;
|
||||
i++;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -342,6 +342,7 @@ decode_fpu(unsigned int Fpu_register[], unsigned int trap_counts[])
|
|||
return SIGNALCODE(SIGFPE, FPE_FLTINV);
|
||||
case DIVISIONBYZEROEXCEPTION:
|
||||
update_trap_counts(Fpu_register, aflags, bflags, trap_counts);
|
||||
Clear_excp_register(exception_index);
|
||||
return SIGNALCODE(SIGFPE, FPE_FLTDIV);
|
||||
case INEXACTEXCEPTION:
|
||||
update_trap_counts(Fpu_register, aflags, bflags, trap_counts);
|
||||
|
|
|
|||
|
|
@ -158,9 +158,11 @@ drivers-$(CONFIG_OPROFILE) += arch/powerpc/oprofile/
|
|||
# Default to zImage, override when needed
|
||||
all: zImage
|
||||
|
||||
BOOT_TARGETS = zImage zImage.initrd uImage zImage% dtbImage% treeImage.% cuImage.% simpleImage.%
|
||||
# With make 3.82 we cannot mix normal and wildcard targets
|
||||
BOOT_TARGETS1 := zImage zImage.initrd uImage
|
||||
BOOT_TARGETS2 := zImage% dtbImage% treeImage.% cuImage.% simpleImage.%
|
||||
|
||||
PHONY += $(BOOT_TARGETS)
|
||||
PHONY += $(BOOT_TARGETS1) $(BOOT_TARGETS2)
|
||||
|
||||
boot := arch/$(ARCH)/boot
|
||||
|
||||
|
|
@ -175,10 +177,16 @@ relocs_check: arch/powerpc/relocs_check.pl vmlinux
|
|||
zImage: relocs_check
|
||||
endif
|
||||
|
||||
$(BOOT_TARGETS): vmlinux
|
||||
$(BOOT_TARGETS1): vmlinux
|
||||
$(Q)$(MAKE) ARCH=ppc64 $(build)=$(boot) $(patsubst %,$(boot)/%,$@)
|
||||
$(BOOT_TARGETS2): vmlinux
|
||||
$(Q)$(MAKE) ARCH=ppc64 $(build)=$(boot) $(patsubst %,$(boot)/%,$@)
|
||||
|
||||
bootwrapper_install %.dtb:
|
||||
|
||||
bootwrapper_install:
|
||||
$(Q)$(MAKE) ARCH=ppc64 $(build)=$(boot) $(patsubst %,$(boot)/%,$@)
|
||||
|
||||
%.dtb:
|
||||
$(Q)$(MAKE) ARCH=ppc64 $(build)=$(boot) $(patsubst %,$(boot)/%,$@)
|
||||
|
||||
define archhelp
|
||||
|
|
|
|||
|
|
@ -133,7 +133,7 @@ static inline compat_uptr_t ptr_to_compat(void __user *uptr)
|
|||
return (u32)(unsigned long)uptr;
|
||||
}
|
||||
|
||||
static inline void __user *compat_alloc_user_space(long len)
|
||||
static inline void __user *arch_compat_alloc_user_space(long len)
|
||||
{
|
||||
struct pt_regs *regs = current->thread.regs;
|
||||
unsigned long usp = regs->gpr[1];
|
||||
|
|
|
|||
|
|
@ -135,43 +135,5 @@ static inline int irqs_disabled_flags(unsigned long flags)
|
|||
*/
|
||||
struct irq_chip;
|
||||
|
||||
#ifdef CONFIG_PERF_EVENTS
|
||||
|
||||
#ifdef CONFIG_PPC64
|
||||
static inline unsigned long test_perf_event_pending(void)
|
||||
{
|
||||
unsigned long x;
|
||||
|
||||
asm volatile("lbz %0,%1(13)"
|
||||
: "=r" (x)
|
||||
: "i" (offsetof(struct paca_struct, perf_event_pending)));
|
||||
return x;
|
||||
}
|
||||
|
||||
static inline void set_perf_event_pending(void)
|
||||
{
|
||||
asm volatile("stb %0,%1(13)" : :
|
||||
"r" (1),
|
||||
"i" (offsetof(struct paca_struct, perf_event_pending)));
|
||||
}
|
||||
|
||||
static inline void clear_perf_event_pending(void)
|
||||
{
|
||||
asm volatile("stb %0,%1(13)" : :
|
||||
"r" (0),
|
||||
"i" (offsetof(struct paca_struct, perf_event_pending)));
|
||||
}
|
||||
#endif /* CONFIG_PPC64 */
|
||||
|
||||
#else /* CONFIG_PERF_EVENTS */
|
||||
|
||||
static inline unsigned long test_perf_event_pending(void)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static inline void clear_perf_event_pending(void) {}
|
||||
#endif /* CONFIG_PERF_EVENTS */
|
||||
|
||||
#endif /* __KERNEL__ */
|
||||
#endif /* _ASM_POWERPC_HW_IRQ_H */
|
||||
|
|
|
|||
|
|
@ -137,6 +137,11 @@ struct device_node * find_device_pe(struct device_node *dn);
|
|||
void eeh_sysfs_add_device(struct pci_dev *pdev);
|
||||
void eeh_sysfs_remove_device(struct pci_dev *pdev);
|
||||
|
||||
static inline const char *eeh_pci_name(struct pci_dev *pdev)
|
||||
{
|
||||
return pdev ? pci_name(pdev) : "<null>";
|
||||
}
|
||||
|
||||
#endif /* CONFIG_EEH */
|
||||
|
||||
#else /* CONFIG_PCI */
|
||||
|
|
|
|||
|
|
@ -133,7 +133,6 @@ int main(void)
|
|||
DEFINE(PACAKMSR, offsetof(struct paca_struct, kernel_msr));
|
||||
DEFINE(PACASOFTIRQEN, offsetof(struct paca_struct, soft_enabled));
|
||||
DEFINE(PACAHARDIRQEN, offsetof(struct paca_struct, hard_enabled));
|
||||
DEFINE(PACAPERFPEND, offsetof(struct paca_struct, perf_event_pending));
|
||||
DEFINE(PACACONTEXTID, offsetof(struct paca_struct, context.id));
|
||||
#ifdef CONFIG_PPC_MM_SLICES
|
||||
DEFINE(PACALOWSLICESPSIZE, offsetof(struct paca_struct,
|
||||
|
|
|
|||
|
|
@ -556,15 +556,6 @@ ALT_FW_FTR_SECTION_END_IFCLR(FW_FEATURE_ISERIES)
|
|||
2:
|
||||
TRACE_AND_RESTORE_IRQ(r5);
|
||||
|
||||
#ifdef CONFIG_PERF_EVENTS
|
||||
/* check paca->perf_event_pending if we're enabling ints */
|
||||
lbz r3,PACAPERFPEND(r13)
|
||||
and. r3,r3,r5
|
||||
beq 27f
|
||||
bl .perf_event_do_pending
|
||||
27:
|
||||
#endif /* CONFIG_PERF_EVENTS */
|
||||
|
||||
/* extract EE bit and use it to restore paca->hard_enabled */
|
||||
ld r3,_MSR(r1)
|
||||
rldicl r4,r3,49,63 /* r0 = (r3 >> 15) & 1 */
|
||||
|
|
|
|||
|
|
@ -563,15 +563,21 @@ __secondary_start:
|
|||
/* Set thread priority to MEDIUM */
|
||||
HMT_MEDIUM
|
||||
|
||||
/* Do early setup for that CPU (stab, slb, hash table pointer) */
|
||||
bl .early_setup_secondary
|
||||
|
||||
/* Initialize the kernel stack. Just a repeat for iSeries. */
|
||||
LOAD_REG_ADDR(r3, current_set)
|
||||
sldi r28,r24,3 /* get current_set[cpu#] */
|
||||
ldx r1,r3,r28
|
||||
addi r1,r1,THREAD_SIZE-STACK_FRAME_OVERHEAD
|
||||
std r1,PACAKSAVE(r13)
|
||||
ldx r14,r3,r28
|
||||
addi r14,r14,THREAD_SIZE-STACK_FRAME_OVERHEAD
|
||||
std r14,PACAKSAVE(r13)
|
||||
|
||||
/* Do early setup for that CPU (stab, slb, hash table pointer) */
|
||||
bl .early_setup_secondary
|
||||
|
||||
/*
|
||||
* setup the new stack pointer, but *don't* use this until
|
||||
* translation is on.
|
||||
*/
|
||||
mr r1, r14
|
||||
|
||||
/* Clear backchain so we get nice backtraces */
|
||||
li r7,0
|
||||
|
|
|
|||
|
|
@ -53,7 +53,6 @@
|
|||
#include <linux/bootmem.h>
|
||||
#include <linux/pci.h>
|
||||
#include <linux/debugfs.h>
|
||||
#include <linux/perf_event.h>
|
||||
|
||||
#include <asm/uaccess.h>
|
||||
#include <asm/system.h>
|
||||
|
|
@ -138,11 +137,6 @@ notrace void raw_local_irq_restore(unsigned long en)
|
|||
}
|
||||
#endif /* CONFIG_PPC_STD_MMU_64 */
|
||||
|
||||
if (test_perf_event_pending()) {
|
||||
clear_perf_event_pending();
|
||||
perf_event_do_pending();
|
||||
}
|
||||
|
||||
/*
|
||||
* if (get_paca()->hard_enabled) return;
|
||||
* But again we need to take care that gcc gets hard_enabled directly
|
||||
|
|
|
|||
|
|
@ -173,9 +173,11 @@ static int p970_marked_instr_event(u64 event)
|
|||
switch (unit) {
|
||||
case PM_VPU:
|
||||
mask = 0x4c; /* byte 0 bits 2,3,6 */
|
||||
break;
|
||||
case PM_LSU0:
|
||||
/* byte 2 bits 0,2,3,4,6; all of byte 1 */
|
||||
mask = 0x085dff00;
|
||||
break;
|
||||
case PM_LSU1L:
|
||||
mask = 0x50 << 24; /* byte 3 bits 4,6 */
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -530,25 +530,60 @@ void __init iSeries_time_init_early(void)
|
|||
}
|
||||
#endif /* CONFIG_PPC_ISERIES */
|
||||
|
||||
#if defined(CONFIG_PERF_EVENTS) && defined(CONFIG_PPC32)
|
||||
DEFINE_PER_CPU(u8, perf_event_pending);
|
||||
#ifdef CONFIG_PERF_EVENTS
|
||||
|
||||
void set_perf_event_pending(void)
|
||||
/*
|
||||
* 64-bit uses a byte in the PACA, 32-bit uses a per-cpu variable...
|
||||
*/
|
||||
#ifdef CONFIG_PPC64
|
||||
static inline unsigned long test_perf_event_pending(void)
|
||||
{
|
||||
get_cpu_var(perf_event_pending) = 1;
|
||||
set_dec(1);
|
||||
put_cpu_var(perf_event_pending);
|
||||
unsigned long x;
|
||||
|
||||
asm volatile("lbz %0,%1(13)"
|
||||
: "=r" (x)
|
||||
: "i" (offsetof(struct paca_struct, perf_event_pending)));
|
||||
return x;
|
||||
}
|
||||
|
||||
static inline void set_perf_event_pending_flag(void)
|
||||
{
|
||||
asm volatile("stb %0,%1(13)" : :
|
||||
"r" (1),
|
||||
"i" (offsetof(struct paca_struct, perf_event_pending)));
|
||||
}
|
||||
|
||||
static inline void clear_perf_event_pending(void)
|
||||
{
|
||||
asm volatile("stb %0,%1(13)" : :
|
||||
"r" (0),
|
||||
"i" (offsetof(struct paca_struct, perf_event_pending)));
|
||||
}
|
||||
|
||||
#else /* 32-bit */
|
||||
|
||||
DEFINE_PER_CPU(u8, perf_event_pending);
|
||||
|
||||
#define set_perf_event_pending_flag() __get_cpu_var(perf_event_pending) = 1
|
||||
#define test_perf_event_pending() __get_cpu_var(perf_event_pending)
|
||||
#define clear_perf_event_pending() __get_cpu_var(perf_event_pending) = 0
|
||||
|
||||
#else /* CONFIG_PERF_EVENTS && CONFIG_PPC32 */
|
||||
#endif /* 32 vs 64 bit */
|
||||
|
||||
void set_perf_event_pending(void)
|
||||
{
|
||||
preempt_disable();
|
||||
set_perf_event_pending_flag();
|
||||
set_dec(1);
|
||||
preempt_enable();
|
||||
}
|
||||
|
||||
#else /* CONFIG_PERF_EVENTS */
|
||||
|
||||
#define test_perf_event_pending() 0
|
||||
#define clear_perf_event_pending()
|
||||
|
||||
#endif /* CONFIG_PERF_EVENTS && CONFIG_PPC32 */
|
||||
#endif /* CONFIG_PERF_EVENTS */
|
||||
|
||||
/*
|
||||
* For iSeries shared processors, we have to let the hypervisor
|
||||
|
|
@ -576,10 +611,6 @@ void timer_interrupt(struct pt_regs * regs)
|
|||
set_dec(DECREMENTER_MAX);
|
||||
|
||||
#ifdef CONFIG_PPC32
|
||||
if (test_perf_event_pending()) {
|
||||
clear_perf_event_pending();
|
||||
perf_event_do_pending();
|
||||
}
|
||||
if (atomic_read(&ppc_n_lost_interrupts) != 0)
|
||||
do_IRQ(regs);
|
||||
#endif
|
||||
|
|
@ -597,6 +628,11 @@ void timer_interrupt(struct pt_regs * regs)
|
|||
|
||||
calculate_steal_time();
|
||||
|
||||
if (test_perf_event_pending()) {
|
||||
clear_perf_event_pending();
|
||||
perf_event_do_pending();
|
||||
}
|
||||
|
||||
#ifdef CONFIG_PPC_ISERIES
|
||||
if (firmware_has_feature(FW_FEATURE_ISERIES))
|
||||
get_lppaca()->int_dword.fields.decr_int = 0;
|
||||
|
|
@ -828,7 +864,8 @@ static cycle_t timebase_read(struct clocksource *cs)
|
|||
return (cycle_t)get_tb();
|
||||
}
|
||||
|
||||
void update_vsyscall(struct timespec *wall_time, struct clocksource *clock)
|
||||
void update_vsyscall(struct timespec *wall_time, struct clocksource *clock,
|
||||
u32 mult)
|
||||
{
|
||||
u64 t2x, stamp_xsec;
|
||||
|
||||
|
|
@ -841,7 +878,7 @@ void update_vsyscall(struct timespec *wall_time, struct clocksource *clock)
|
|||
|
||||
/* XXX this assumes clock->shift == 22 */
|
||||
/* 4611686018 ~= 2^(20+64-22) / 1e9 */
|
||||
t2x = (u64) clock->mult * 4611686018ULL;
|
||||
t2x = (u64) mult * 4611686018ULL;
|
||||
stamp_xsec = (u64) xtime.tv_nsec * XSEC_PER_SEC;
|
||||
do_div(stamp_xsec, 1000000000);
|
||||
stamp_xsec += (u64) xtime.tv_sec * XSEC_PER_SEC;
|
||||
|
|
|
|||
|
|
@ -176,7 +176,8 @@ struct kvm_vcpu *kvm_arch_vcpu_create(struct kvm *kvm, unsigned int id)
|
|||
{
|
||||
struct kvm_vcpu *vcpu;
|
||||
vcpu = kvmppc_core_vcpu_create(kvm, id);
|
||||
kvmppc_create_vcpu_debugfs(vcpu, id);
|
||||
if (!IS_ERR(vcpu))
|
||||
kvmppc_create_vcpu_debugfs(vcpu, id);
|
||||
return vcpu;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -71,7 +71,7 @@ _GLOBAL(strcmp)
|
|||
|
||||
_GLOBAL(strncmp)
|
||||
PPC_LCMPI r5,0
|
||||
beqlr
|
||||
ble- 2f
|
||||
mtctr r5
|
||||
addi r5,r3,-1
|
||||
addi r4,r4,-1
|
||||
|
|
@ -82,6 +82,8 @@ _GLOBAL(strncmp)
|
|||
beqlr 1
|
||||
bdnzt eq,1b
|
||||
blr
|
||||
2: li r3,0
|
||||
blr
|
||||
|
||||
_GLOBAL(strlen)
|
||||
addi r4,r3,-1
|
||||
|
|
|
|||
|
|
@ -131,15 +131,10 @@ void settlbcam(int index, unsigned long virt, phys_addr_t phys,
|
|||
TLBCAM[index].MAS3 = (phys & PAGE_MASK) | MAS3_SX | MAS3_SR;
|
||||
TLBCAM[index].MAS3 |= ((flags & _PAGE_RW) ? MAS3_SW : 0);
|
||||
|
||||
#ifndef CONFIG_KGDB /* want user access for breakpoints */
|
||||
if (flags & _PAGE_USER) {
|
||||
TLBCAM[index].MAS3 |= MAS3_UX | MAS3_UR;
|
||||
TLBCAM[index].MAS3 |= ((flags & _PAGE_RW) ? MAS3_UW : 0);
|
||||
}
|
||||
#else
|
||||
TLBCAM[index].MAS3 |= MAS3_UX | MAS3_UR;
|
||||
TLBCAM[index].MAS3 |= ((flags & _PAGE_RW) ? MAS3_UW : 0);
|
||||
#endif
|
||||
|
||||
tlbcam_addrs[index].start = virt;
|
||||
tlbcam_addrs[index].limit = virt + size - 1;
|
||||
|
|
|
|||
|
|
@ -1077,7 +1077,7 @@ static int calculate_lfsr(int n)
|
|||
index = ENTRIES-1;
|
||||
|
||||
/* make sure index is valid */
|
||||
if ((index > ENTRIES) || (index < 0))
|
||||
if ((index >= ENTRIES) || (index < 0))
|
||||
index = ENTRIES-1;
|
||||
|
||||
return initial_lfsr[index];
|
||||
|
|
|
|||
|
|
@ -491,7 +491,7 @@ int eeh_dn_check_failure(struct device_node *dn, struct pci_dev *dev)
|
|||
pdn->eeh_mode & EEH_MODE_NOCHECK) {
|
||||
ignored_check++;
|
||||
pr_debug("EEH: Ignored check (%x) for %s %s\n",
|
||||
pdn->eeh_mode, pci_name (dev), dn->full_name);
|
||||
pdn->eeh_mode, eeh_pci_name(dev), dn->full_name);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
@ -515,7 +515,7 @@ int eeh_dn_check_failure(struct device_node *dn, struct pci_dev *dev)
|
|||
printk (KERN_ERR "EEH: %d reads ignored for recovering device at "
|
||||
"location=%s driver=%s pci addr=%s\n",
|
||||
pdn->eeh_check_count, location,
|
||||
dev->driver->name, pci_name(dev));
|
||||
dev->driver->name, eeh_pci_name(dev));
|
||||
printk (KERN_ERR "EEH: Might be infinite loop in %s driver\n",
|
||||
dev->driver->name);
|
||||
dump_stack();
|
||||
|
|
|
|||
|
|
@ -353,7 +353,7 @@ struct pci_dn * handle_eeh_events (struct eeh_event *event)
|
|||
location = location ? location : "unknown";
|
||||
printk(KERN_ERR "EEH: Error: Cannot find partition endpoint "
|
||||
"for location=%s pci addr=%s\n",
|
||||
location, pci_name(event->dev));
|
||||
location, eeh_pci_name(event->dev));
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
@ -384,7 +384,7 @@ struct pci_dn * handle_eeh_events (struct eeh_event *event)
|
|||
pci_str = pci_name (frozen_pdn->pcidev);
|
||||
drv_str = pcid_name (frozen_pdn->pcidev);
|
||||
} else {
|
||||
pci_str = pci_name (event->dev);
|
||||
pci_str = eeh_pci_name(event->dev);
|
||||
drv_str = pcid_name (event->dev);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -80,7 +80,7 @@ static int eeh_event_handler(void * dummy)
|
|||
eeh_mark_slot(event->dn, EEH_MODE_RECOVERING);
|
||||
|
||||
printk(KERN_INFO "EEH: Detected PCI bus error on device %s\n",
|
||||
pci_name(event->dev));
|
||||
eeh_pci_name(event->dev));
|
||||
|
||||
pdn = handle_eeh_events(event);
|
||||
|
||||
|
|
|
|||
|
|
@ -66,30 +66,6 @@ static void pseries_mach_cpu_die(void)
|
|||
for(;;);
|
||||
}
|
||||
|
||||
static int qcss_tok; /* query-cpu-stopped-state token */
|
||||
|
||||
/* Get state of physical CPU.
|
||||
* Return codes:
|
||||
* 0 - The processor is in the RTAS stopped state
|
||||
* 1 - stop-self is in progress
|
||||
* 2 - The processor is not in the RTAS stopped state
|
||||
* -1 - Hardware Error
|
||||
* -2 - Hardware Busy, Try again later.
|
||||
*/
|
||||
static int query_cpu_stopped(unsigned int pcpu)
|
||||
{
|
||||
int cpu_status, status;
|
||||
|
||||
status = rtas_call(qcss_tok, 1, 2, &cpu_status, pcpu);
|
||||
if (status != 0) {
|
||||
printk(KERN_ERR
|
||||
"RTAS query-cpu-stopped-state failed: %i\n", status);
|
||||
return status;
|
||||
}
|
||||
|
||||
return cpu_status;
|
||||
}
|
||||
|
||||
static int pseries_cpu_disable(void)
|
||||
{
|
||||
int cpu = smp_processor_id();
|
||||
|
|
@ -113,8 +89,9 @@ static void pseries_cpu_die(unsigned int cpu)
|
|||
unsigned int pcpu = get_hard_smp_processor_id(cpu);
|
||||
|
||||
for (tries = 0; tries < 25; tries++) {
|
||||
cpu_status = query_cpu_stopped(pcpu);
|
||||
if (cpu_status == 0 || cpu_status == -1)
|
||||
cpu_status = smp_query_cpu_stopped(pcpu);
|
||||
if (cpu_status == QCSS_STOPPED ||
|
||||
cpu_status == QCSS_HARDWARE_ERROR)
|
||||
break;
|
||||
cpu_relax();
|
||||
}
|
||||
|
|
@ -256,6 +233,7 @@ static int __init pseries_cpu_hotplug_init(void)
|
|||
{
|
||||
struct device_node *np;
|
||||
const char *typep;
|
||||
int qcss_tok;
|
||||
|
||||
for_each_node_by_name(np, "interrupt-controller") {
|
||||
typep = of_get_property(np, "compatible", NULL);
|
||||
|
|
|
|||
|
|
@ -4,6 +4,14 @@
|
|||
#include <asm/hvcall.h>
|
||||
#include <asm/page.h>
|
||||
|
||||
/* Get state of physical CPU from query_cpu_stopped */
|
||||
int smp_query_cpu_stopped(unsigned int pcpu);
|
||||
#define QCSS_STOPPED 0
|
||||
#define QCSS_STOPPING 1
|
||||
#define QCSS_NOT_STOPPED 2
|
||||
#define QCSS_HARDWARE_ERROR -1
|
||||
#define QCSS_HARDWARE_BUSY -2
|
||||
|
||||
static inline long poll_pending(void)
|
||||
{
|
||||
return plpar_hcall_norets(H_POLL_PENDING);
|
||||
|
|
|
|||
|
|
@ -56,6 +56,28 @@
|
|||
*/
|
||||
static cpumask_t of_spin_map;
|
||||
|
||||
/* Query where a cpu is now. Return codes #defined in plpar_wrappers.h */
|
||||
int smp_query_cpu_stopped(unsigned int pcpu)
|
||||
{
|
||||
int cpu_status, status;
|
||||
int qcss_tok = rtas_token("query-cpu-stopped-state");
|
||||
|
||||
if (qcss_tok == RTAS_UNKNOWN_SERVICE) {
|
||||
printk(KERN_INFO "Firmware doesn't support "
|
||||
"query-cpu-stopped-state\n");
|
||||
return QCSS_HARDWARE_ERROR;
|
||||
}
|
||||
|
||||
status = rtas_call(qcss_tok, 1, 2, &cpu_status, pcpu);
|
||||
if (status != 0) {
|
||||
printk(KERN_ERR
|
||||
"RTAS query-cpu-stopped-state failed: %i\n", status);
|
||||
return status;
|
||||
}
|
||||
|
||||
return cpu_status;
|
||||
}
|
||||
|
||||
/**
|
||||
* smp_startup_cpu() - start the given cpu
|
||||
*
|
||||
|
|
@ -81,6 +103,12 @@ static inline int __devinit smp_startup_cpu(unsigned int lcpu)
|
|||
|
||||
pcpu = get_hard_smp_processor_id(lcpu);
|
||||
|
||||
/* Check to see if the CPU out of FW already for kexec */
|
||||
if (smp_query_cpu_stopped(pcpu) == QCSS_NOT_STOPPED){
|
||||
cpu_set(lcpu, of_spin_map);
|
||||
return 1;
|
||||
}
|
||||
|
||||
/* Fixup atomic count: it exited inside IRQ handler. */
|
||||
task_thread_info(paca[lcpu].__current)->preempt_count = 0;
|
||||
|
||||
|
|
|
|||
|
|
@ -180,7 +180,7 @@ static inline int is_compat_task(void)
|
|||
|
||||
#endif
|
||||
|
||||
static inline void __user *compat_alloc_user_space(long len)
|
||||
static inline void __user *arch_compat_alloc_user_space(long len)
|
||||
{
|
||||
unsigned long stack;
|
||||
|
||||
|
|
|
|||
|
|
@ -183,6 +183,7 @@ struct s390_idle_data {
|
|||
unsigned long long idle_count;
|
||||
unsigned long long idle_enter;
|
||||
unsigned long long idle_time;
|
||||
int nohz_delay;
|
||||
};
|
||||
|
||||
DECLARE_PER_CPU(struct s390_idle_data, s390_idle);
|
||||
|
|
@ -198,4 +199,11 @@ static inline void s390_idle_check(void)
|
|||
vtime_start_cpu();
|
||||
}
|
||||
|
||||
static inline int s390_nohz_delay(int cpu)
|
||||
{
|
||||
return per_cpu(s390_idle, cpu).nohz_delay != 0;
|
||||
}
|
||||
|
||||
#define arch_needs_cpu(cpu) s390_nohz_delay(cpu)
|
||||
|
||||
#endif /* _S390_CPUTIME_H */
|
||||
|
|
|
|||
|
|
@ -95,7 +95,6 @@ EXPORT_SYMBOL_GPL(s390_handle_mcck);
|
|||
static int notrace s390_revalidate_registers(struct mci *mci)
|
||||
{
|
||||
int kill_task;
|
||||
u64 tmpclock;
|
||||
u64 zero;
|
||||
void *fpt_save_area, *fpt_creg_save_area;
|
||||
|
||||
|
|
@ -214,11 +213,10 @@ static int notrace s390_revalidate_registers(struct mci *mci)
|
|||
: "0", "cc");
|
||||
#endif
|
||||
/* Revalidate clock comparator register */
|
||||
asm volatile(
|
||||
" stck 0(%1)\n"
|
||||
" sckc 0(%1)"
|
||||
: "=m" (tmpclock) : "a" (&(tmpclock)) : "cc", "memory");
|
||||
|
||||
if (S390_lowcore.clock_comparator == -1)
|
||||
set_clock_comparator(get_clock());
|
||||
else
|
||||
set_clock_comparator(S390_lowcore.clock_comparator);
|
||||
/* Check if old PSW is valid */
|
||||
if (!mci->wp)
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -632,7 +632,7 @@ long compat_arch_ptrace(struct task_struct *child, compat_long_t request,
|
|||
|
||||
asmlinkage long do_syscall_trace_enter(struct pt_regs *regs)
|
||||
{
|
||||
long ret;
|
||||
long ret = 0;
|
||||
|
||||
/* Do the secure computing check first. */
|
||||
secure_computing(regs->gprs[2]);
|
||||
|
|
@ -641,7 +641,6 @@ asmlinkage long do_syscall_trace_enter(struct pt_regs *regs)
|
|||
* The sysc_tracesys code in entry.S stored the system
|
||||
* call number to gprs[2].
|
||||
*/
|
||||
ret = regs->gprs[2];
|
||||
if (test_thread_flag(TIF_SYSCALL_TRACE) &&
|
||||
(tracehook_report_syscall_entry(regs) ||
|
||||
regs->gprs[2] >= NR_syscalls)) {
|
||||
|
|
@ -663,7 +662,7 @@ asmlinkage long do_syscall_trace_enter(struct pt_regs *regs)
|
|||
regs->gprs[2], regs->orig_gpr2,
|
||||
regs->gprs[3], regs->gprs[4],
|
||||
regs->gprs[5]);
|
||||
return ret;
|
||||
return ret ?: regs->gprs[2];
|
||||
}
|
||||
|
||||
asmlinkage void do_syscall_trace_exit(struct pt_regs *regs)
|
||||
|
|
|
|||
|
|
@ -126,6 +126,8 @@ void __irq_entry do_extint(struct pt_regs *regs, unsigned short code)
|
|||
/* Serve timer interrupts first. */
|
||||
clock_comparator_work();
|
||||
kstat_cpu(smp_processor_id()).irqs[EXTERNAL_INTERRUPT]++;
|
||||
if (code != 0x1004)
|
||||
__get_cpu_var(s390_idle).nohz_delay = 1;
|
||||
index = ext_hash(code);
|
||||
for (p = ext_int_hash[index]; p; p = p->next) {
|
||||
if (likely(p->code == code))
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user