diff --git a/[refs] b/[refs]
index bf4537047560..1037b7157b01 100644
--- a/[refs]
+++ b/[refs]
@@ -1,2 +1,2 @@
---
-refs/heads/master: e19c29e8d8d3b2dbc4c9a859f40c3f95ed089441
+refs/heads/master: c4addcb55417a246b4419cbb075a2e4f412a8645
diff --git a/trunk/Documentation/DocBook/media/dvb/dvbproperty.xml b/trunk/Documentation/DocBook/media/dvb/dvbproperty.xml
index c7a4ca517859..ffee1fbbc001 100644
--- a/trunk/Documentation/DocBook/media/dvb/dvbproperty.xml
+++ b/trunk/Documentation/DocBook/media/dvb/dvbproperty.xml
@@ -163,16 +163,14 @@ get/set up to 64 properties. The actual meaning of each property is described on
DTV_FREQUENCY
- Central frequency of the channel.
+ Central frequency of the channel, in HZ.
Notes:
- 1)For satellital delivery systems, it is measured in kHz.
- For the other ones, it is measured in Hz.
- 2)For ISDB-T, the channels are usually transmitted with an offset of 143kHz.
+ 1)For ISDB-T, the channels are usually transmitted with an offset of 143kHz.
E.g. a valid frequncy could be 474143 kHz. The stepping is bound to the bandwidth of
the channel which is 6MHz.
- 3)As in ISDB-Tsb the channel consists of only one or three segments the
+ 2)As in ISDB-Tsb the channel consists of only one or three segments the
frequency step is 429kHz, 3*429 respectively. As for ISDB-T the
central frequency of the channel is expected.
@@ -737,10 +735,14 @@ typedef enum fe_hierarchy {
DTV_TUNE
DTV_CLEAR
DTV_FREQUENCY
+ DTV_MODULATION
DTV_BANDWIDTH_HZ
DTV_INVERSION
+ DTV_CODE_RATE_HP
+ DTV_CODE_RATE_LP
DTV_GUARD_INTERVAL
DTV_TRANSMISSION_MODE
+ DTV_HIERARCHY
DTV_ISDBT_LAYER_ENABLED
DTV_ISDBT_PARTIAL_RECEPTION
DTV_ISDBT_SOUND_BROADCASTING
diff --git a/trunk/Documentation/DocBook/media/v4l/vidioc-g-ext-ctrls.xml b/trunk/Documentation/DocBook/media/v4l/vidioc-g-ext-ctrls.xml
index b17a7aac6997..6f1f9a629dc3 100644
--- a/trunk/Documentation/DocBook/media/v4l/vidioc-g-ext-ctrls.xml
+++ b/trunk/Documentation/DocBook/media/v4l/vidioc-g-ext-ctrls.xml
@@ -183,12 +183,7 @@ applications must set the array to zero.
__u32
ctrl_class
The control class to which all controls belong, see
-. Drivers that use a kernel framework for handling
-controls will also accept a value of 0 here, meaning that the controls can
-belong to any control class. Whether drivers support this can be tested by setting
-ctrl_class to 0 and calling VIDIOC_TRY_EXT_CTRLS
-with a count of 0. If that succeeds, then the driver
-supports this feature.
+.
__u32
@@ -199,13 +194,10 @@ also be zero.
__u32
error_idx
- Set by the driver in case of an error. If it is equal
-to count, then no actual changes were made to
-controls. In other words, the error was not associated with setting a particular
-control. If it is another value, then only the controls up to error_idx-1
-were modified and control error_idx is the one that
-caused the error. The error_idx value is undefined
-if the ioctl returned 0 (success).
+ Set by the driver in case of an error. It is the
+index of the control causing the error or equal to 'count' when the
+error is not associated with a particular control. Undefined when the
+ioctl returns 0 (success).
__u32
diff --git a/trunk/Documentation/DocBook/media/v4l/vidioc-g-fbuf.xml b/trunk/Documentation/DocBook/media/v4l/vidioc-g-fbuf.xml
index 7c63815e7afd..93817f337033 100644
--- a/trunk/Documentation/DocBook/media/v4l/vidioc-g-fbuf.xml
+++ b/trunk/Documentation/DocBook/media/v4l/vidioc-g-fbuf.xml
@@ -364,20 +364,15 @@ capability and it is cleared otherwise.
V4L2_FBUF_FLAG_OVERLAY
0x0002
- If this flag is set for a video capture device, then the
-driver will set the initial overlay size to cover the full framebuffer size,
-otherwise the existing overlay size (as set by &VIDIOC-S-FMT;) will be used.
-
-Only one video capture driver (bttv) supports this flag. The use of this flag
-for capture devices is deprecated. There is no way to detect which drivers
-support this flag, so the only reliable method of setting the overlay size is
-through &VIDIOC-S-FMT;.
-
-If this flag is set for a video output device, then the video output overlay
-window is relative to the top-left corner of the framebuffer and restricted
-to the size of the framebuffer. If it is cleared, then the video output
-overlay window is relative to the video output display.
-
+ The frame buffer is an overlay surface the same
+size as the capture. [?]
+
+
+ The purpose of
+V4L2_FBUF_FLAG_OVERLAY was never quite clear.
+Most drivers seem to ignore this flag. For compatibility with the
+bttv driver applications should set the
+V4L2_FBUF_FLAG_OVERLAY flag.
V4L2_FBUF_FLAG_CHROMAKEY
diff --git a/trunk/Documentation/DocBook/media/v4l/vidioc-g-frequency.xml b/trunk/Documentation/DocBook/media/v4l/vidioc-g-frequency.xml
index 66e9a5257861..16431813bebd 100644
--- a/trunk/Documentation/DocBook/media/v4l/vidioc-g-frequency.xml
+++ b/trunk/Documentation/DocBook/media/v4l/vidioc-g-frequency.xml
@@ -98,11 +98,8 @@ the &v4l2-output; modulator field and the
&v4l2-tuner-type;
type
The tuner type. This is the same value as in the
-&v4l2-tuner; type field. The type must be set
-to V4L2_TUNER_RADIO for /dev/radioX
-device nodes, and to V4L2_TUNER_ANALOG_TV
-for all others. The field is not applicable to modulators, &ie; ignored
-by drivers.
+&v4l2-tuner; type field. The field is not
+applicable to modulators, &ie; ignored by drivers.
__u32
diff --git a/trunk/Documentation/DocBook/media/v4l/vidioc-g-input.xml b/trunk/Documentation/DocBook/media/v4l/vidioc-g-input.xml
index 1d43065090dd..08ae82f131f2 100644
--- a/trunk/Documentation/DocBook/media/v4l/vidioc-g-input.xml
+++ b/trunk/Documentation/DocBook/media/v4l/vidioc-g-input.xml
@@ -61,8 +61,8 @@ desired input in an integer and call the
VIDIOC_S_INPUT ioctl with a pointer to this
integer. Side effects are possible. For example inputs may support
different video standards, so the driver may implicitly switch the
-current standard. Because of these possible side effects applications
-must select an input before querying or negotiating any other parameters.
+current standard. It is good practice to select an input before
+querying or negotiating any other parameters.
Information about video inputs is available using the
&VIDIOC-ENUMINPUT; ioctl.
diff --git a/trunk/Documentation/DocBook/media/v4l/vidioc-g-output.xml b/trunk/Documentation/DocBook/media/v4l/vidioc-g-output.xml
index 4533068ecb8a..fd45f1c13ccf 100644
--- a/trunk/Documentation/DocBook/media/v4l/vidioc-g-output.xml
+++ b/trunk/Documentation/DocBook/media/v4l/vidioc-g-output.xml
@@ -61,9 +61,8 @@ desired output in an integer and call the
VIDIOC_S_OUTPUT ioctl with a pointer to this integer.
Side effects are possible. For example outputs may support different
video standards, so the driver may implicitly switch the current
-standard.
-standard. Because of these possible side effects applications
-must select an output before querying or negotiating any other parameters.
+standard. It is good practice to select an output before querying or
+negotiating any other parameters.
Information about video outputs is available using the
&VIDIOC-ENUMOUTPUT; ioctl.
diff --git a/trunk/Documentation/acpi/apei/einj.txt b/trunk/Documentation/acpi/apei/einj.txt
index e7cc36397217..5cc699ba5453 100644
--- a/trunk/Documentation/acpi/apei/einj.txt
+++ b/trunk/Documentation/acpi/apei/einj.txt
@@ -47,53 +47,20 @@ directory apei/einj. The following files are provided.
- param1
This file is used to set the first error parameter value. Effect of
- parameter depends on error_type specified.
+ parameter depends on error_type specified. For memory error, this is
+ physical memory address. Only available if param_extension module
+ parameter is specified.
- param2
This file is used to set the second error parameter value. Effect of
- parameter depends on error_type specified.
-
-BIOS versions based in the ACPI 4.0 specification have limited options
-to control where the errors are injected. Your BIOS may support an
-extension (enabled with the param_extension=1 module parameter, or
-boot command line einj.param_extension=1). This allows the address
-and mask for memory injections to be specified by the param1 and
-param2 files in apei/einj.
-
-BIOS versions using the ACPI 5.0 specification have more control over
-the target of the injection. For processor related errors (type 0x1,
-0x2 and 0x4) the APICID of the target should be provided using the
-param1 file in apei/einj. For memory errors (type 0x8, 0x10 and 0x20)
-the address is set using param1 with a mask in param2 (0x0 is equivalent
-to all ones). For PCI express errors (type 0x40, 0x80 and 0x100) the
-segment, bus, device and function are specified using param1:
-
- 31 24 23 16 15 11 10 8 7 0
- +-------------------------------------------------+
- | segment | bus | device | function | reserved |
- +-------------------------------------------------+
-
-An ACPI 5.0 BIOS may also allow vendor specific errors to be injected.
-In this case a file named vendor will contain identifying information
-from the BIOS that hopefully will allow an application wishing to use
-the vendor specific extension to tell that they are running on a BIOS
-that supports it. All vendor extensions have the 0x80000000 bit set in
-error_type. A file vendor_flags controls the interpretation of param1
-and param2 (1 = PROCESSOR, 2 = MEMORY, 4 = PCI). See your BIOS vendor
-documentation for details (and expect changes to this API if vendors
-creativity in using this feature expands beyond our expectations).
-
-Example:
-# cd /sys/kernel/debug/apei/einj
-# cat available_error_type # See which errors can be injected
-0x00000002 Processor Uncorrectable non-fatal
-0x00000008 Memory Correctable
-0x00000010 Memory Uncorrectable non-fatal
-# echo 0x12345000 > param1 # Set memory address for injection
-# echo 0xfffffffffffff000 > param2 # Mask - anywhere in this page
-# echo 0x8 > error_type # Choose correctable memory error
-# echo 1 > error_inject # Inject now
+ parameter depends on error_type specified. For memory error, this is
+ physical memory address mask. Only available if param_extension
+ module parameter is specified.
+Injecting parameter support is a BIOS version specific extension, that
+is, it only works on some BIOS version. If you want to use it, please
+make sure your BIOS version has the proper support and specify
+"param_extension=y" in module parameter.
For more information about EINJ, please refer to ACPI specification
-version 4.0, section 17.5 and ACPI 5.0, section 18.6.
+version 4.0, section 17.5.
diff --git a/trunk/Documentation/coccinelle.txt b/trunk/Documentation/coccinelle.txt
index cf44eb6499b4..96b690348ba1 100644
--- a/trunk/Documentation/coccinelle.txt
+++ b/trunk/Documentation/coccinelle.txt
@@ -102,15 +102,9 @@ or
make coccicheck COCCI= MODE=report
- Controlling Which Files are Processed by Coccinelle
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-By default the entire kernel source tree is checked.
-
-To apply Coccinelle to a specific directory, M= can be used.
-For example, to check drivers/net/wireless/ one may write:
+ Using Coccinelle on (modified) files
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- make coccicheck M=drivers/net/wireless/
-
To apply Coccinelle on a file basis, instead of a directory basis, the
following command may be used:
diff --git a/trunk/Documentation/devices.txt b/trunk/Documentation/devices.txt
index 00383186d8fb..cec8864ce4e8 100644
--- a/trunk/Documentation/devices.txt
+++ b/trunk/Documentation/devices.txt
@@ -447,9 +447,6 @@ Your cooperation is appreciated.
234 = /dev/btrfs-control Btrfs control device
235 = /dev/autofs Autofs control device
236 = /dev/mapper/control Device-Mapper control device
- 237 = /dev/loop-control Loopback control device
- 238 = /dev/vhost-net Host kernel accelerator for virtio net
-
240-254 Reserved for local use
255 Reserved for MISC_DYNAMIC_MINOR
diff --git a/trunk/Documentation/devicetree/bindings/dma/atmel-dma.txt b/trunk/Documentation/devicetree/bindings/dma/atmel-dma.txt
deleted file mode 100644
index 3c046ee6e8b5..000000000000
--- a/trunk/Documentation/devicetree/bindings/dma/atmel-dma.txt
+++ /dev/null
@@ -1,14 +0,0 @@
-* Atmel Direct Memory Access Controller (DMA)
-
-Required properties:
-- compatible: Should be "atmel,-dma"
-- reg: Should contain DMA registers location and length
-- interrupts: Should contain DMA interrupt
-
-Examples:
-
-dma@ffffec00 {
- compatible = "atmel,at91sam9g45-dma";
- reg = <0xffffec00 0x200>;
- interrupts = <21>;
-};
diff --git a/trunk/Documentation/devicetree/bindings/i2c/omap-i2c.txt b/trunk/Documentation/devicetree/bindings/i2c/omap-i2c.txt
deleted file mode 100644
index 56564aa4b444..000000000000
--- a/trunk/Documentation/devicetree/bindings/i2c/omap-i2c.txt
+++ /dev/null
@@ -1,30 +0,0 @@
-I2C for OMAP platforms
-
-Required properties :
-- compatible : Must be "ti,omap3-i2c" or "ti,omap4-i2c"
-- ti,hwmods : Must be "i2c", n being the instance number (1-based)
-- #address-cells = <1>;
-- #size-cells = <0>;
-
-Recommended properties :
-- clock-frequency : Desired I2C bus clock frequency in Hz. Otherwise
- the default 100 kHz frequency will be used.
-
-Optional properties:
-- Child nodes conforming to i2c bus binding
-
-Note: Current implementation will fetch base address, irq and dma
-from omap hwmod data base during device registration.
-Future plan is to migrate hwmod data base contents into device tree
-blob so that, all the required data will be used from device tree dts
-file.
-
-Examples :
-
-i2c1: i2c@0 {
- compatible = "ti,omap3-i2c";
- #address-cells = <1>;
- #size-cells = <0>;
- ti,hwmods = "i2c1";
- clock-frequency = <400000>;
-};
diff --git a/trunk/Documentation/dmaengine.txt b/trunk/Documentation/dmaengine.txt
index bbe6cb3d1856..94b7e0f96b38 100644
--- a/trunk/Documentation/dmaengine.txt
+++ b/trunk/Documentation/dmaengine.txt
@@ -75,10 +75,6 @@ The slave DMA usage consists of following steps:
slave_sg - DMA a list of scatter gather buffers from/to a peripheral
dma_cyclic - Perform a cyclic DMA operation from/to a peripheral till the
operation is explicitly stopped.
- interleaved_dma - This is common to Slave as well as M2M clients. For slave
- address of devices' fifo could be already known to the driver.
- Various types of operations could be expressed by setting
- appropriate values to the 'dma_interleaved_template' members.
A non-NULL return of this transfer API represents a "descriptor" for
the given transaction.
@@ -93,10 +89,6 @@ The slave DMA usage consists of following steps:
struct dma_chan *chan, dma_addr_t buf_addr, size_t buf_len,
size_t period_len, enum dma_data_direction direction);
- struct dma_async_tx_descriptor *(*device_prep_interleaved_dma)(
- struct dma_chan *chan, struct dma_interleaved_template *xt,
- unsigned long flags);
-
The peripheral driver is expected to have mapped the scatterlist for
the DMA operation prior to calling device_prep_slave_sg, and must
keep the scatterlist mapped until the DMA operation has completed.
diff --git a/trunk/Documentation/feature-removal-schedule.txt b/trunk/Documentation/feature-removal-schedule.txt
index 1bea46a54b1c..d725c0dfe032 100644
--- a/trunk/Documentation/feature-removal-schedule.txt
+++ b/trunk/Documentation/feature-removal-schedule.txt
@@ -439,6 +439,17 @@ Who: Jean Delvare
----------------------------
+What: For VIDIOC_S_FREQUENCY the type field must match the device node's type.
+ If not, return -EINVAL.
+When: 3.2
+Why: It makes no sense to switch the tuner to radio mode by calling
+ VIDIOC_S_FREQUENCY on a video node, or to switch the tuner to tv mode by
+ calling VIDIOC_S_FREQUENCY on a radio node. This is the first step of a
+ move to more consistent handling of tv and radio tuners.
+Who: Hans Verkuil
+
+----------------------------
+
What: Opening a radio device node will no longer automatically switch the
tuner mode from tv to radio.
When: 3.3
diff --git a/trunk/Documentation/hwmon/it87 b/trunk/Documentation/hwmon/it87
index 23b7def21ba8..6f496a586732 100644
--- a/trunk/Documentation/hwmon/it87
+++ b/trunk/Documentation/hwmon/it87
@@ -26,10 +26,6 @@ Supported chips:
Prefix: 'it8721'
Addresses scanned: from Super I/O config space (8 I/O ports)
Datasheet: Not publicly available
- * IT8728F
- Prefix: 'it8728'
- Addresses scanned: from Super I/O config space (8 I/O ports)
- Datasheet: Not publicly available
* SiS950 [clone of IT8705F]
Prefix: 'it87'
Addresses scanned: from Super I/O config space (8 I/O ports)
@@ -75,7 +71,7 @@ Description
-----------
This driver implements support for the IT8705F, IT8712F, IT8716F,
-IT8718F, IT8720F, IT8721F, IT8726F, IT8728F, IT8758E and SiS950 chips.
+IT8718F, IT8720F, IT8721F, IT8726F, IT8758E and SiS950 chips.
These chips are 'Super I/O chips', supporting floppy disks, infrared ports,
joysticks and other miscellaneous stuff. For hardware monitoring, they
@@ -109,9 +105,6 @@ The IT8726F is just bit enhanced IT8716F with additional hardware
for AMD power sequencing. Therefore the chip will appear as IT8716F
to userspace applications.
-The IT8728F is considered compatible with the IT8721F, until a datasheet
-becomes available (hopefully.)
-
Temperatures are measured in degrees Celsius. An alarm is triggered once
when the Overtemperature Shutdown limit is crossed.
@@ -128,8 +121,8 @@ alarm is triggered if the voltage has crossed a programmable minimum or
maximum limit. Note that minimum in this case always means 'closest to
zero'; this is important for negative voltage measurements. All voltage
inputs can measure voltages between 0 and 4.08 volts, with a resolution of
-0.016 volt (except IT8721F/IT8758E and IT8728F: 0.012 volt.) The battery
-voltage in8 does not have limit registers.
+0.016 volt (except IT8721F/IT8758E: 0.012 volt.) The battery voltage in8 does
+not have limit registers.
On the IT8721F/IT8758E, some voltage inputs are internal and scaled inside
the chip (in7, in8 and optionally in3). The driver handles this transparently
diff --git a/trunk/Documentation/hwmon/lm63 b/trunk/Documentation/hwmon/lm63
index 4d30d209881a..b9843eab1afb 100644
--- a/trunk/Documentation/hwmon/lm63
+++ b/trunk/Documentation/hwmon/lm63
@@ -12,11 +12,6 @@ Supported chips:
Addresses scanned: I2C 0x18 and 0x4e
Datasheet: Publicly available at the National Semiconductor website
http://www.national.com/pf/LM/LM64.html
- * National Semiconductor LM96163
- Prefix: 'lm96163'
- Addresses scanned: I2C 0x4c
- Datasheet: Publicly available at the National Semiconductor website
- http://www.national.com/pf/LM/LM96163.html
Author: Jean Delvare
@@ -54,24 +49,16 @@ value for measuring the speed of the fan. It can measure fan speeds down to
Note that the pin used for fan monitoring is shared with an alert out
function. Depending on how the board designer wanted to use the chip, fan
speed monitoring will or will not be possible. The proper chip configuration
-is left to the BIOS, and the driver will blindly trust it. Only the original
-LM63 suffers from this limitation, the LM64 and LM96163 have separate pins
-for fan monitoring and alert out. On the LM64, monitoring is always enabled;
-on the LM96163 it can be disabled.
+is left to the BIOS, and the driver will blindly trust it.
A PWM output can be used to control the speed of the fan. The LM63 has two
PWM modes: manual and automatic. Automatic mode is not fully implemented yet
(you cannot define your custom PWM/temperature curve), and mode change isn't
supported either.
-The lm63 driver will not update its values more frequently than configured with
-the update_interval sysfs attribute; reading them more often will do no harm,
-but will return 'old' values. Values in the automatic fan control lookup table
-(attributes pwm1_auto_*) have their own independent lifetime of 5 seconds.
+The lm63 driver will not update its values more frequently than every
+second; reading them more often will do no harm, but will return 'old'
+values.
The LM64 is effectively an LM63 with GPIO lines. The driver does not
support these GPIO lines at present.
-
-The LM96163 is an enhanced version of LM63 with improved temperature accuracy
-and better PWM resolution. For LM96163, the external temperature sensor type is
-configurable as CPU embedded diode(1) or 3904 transistor(2).
diff --git a/trunk/Documentation/hwmon/sysfs-interface b/trunk/Documentation/hwmon/sysfs-interface
index 1f4dd855a299..a4aa8f600e09 100644
--- a/trunk/Documentation/hwmon/sysfs-interface
+++ b/trunk/Documentation/hwmon/sysfs-interface
@@ -304,7 +304,7 @@ value (fastest fan speed) wins.
temp[1-*]_type Sensor type selection.
Integers 1 to 6
RW
- 1: CPU embedded diode
+ 1: PII/Celeron Diode
2: 3904 transistor
3: thermal diode
4: thermistor
diff --git a/trunk/Documentation/ioctl/ioctl-number.txt b/trunk/Documentation/ioctl/ioctl-number.txt
index 4840334ea97b..54078ed96b37 100644
--- a/trunk/Documentation/ioctl/ioctl-number.txt
+++ b/trunk/Documentation/ioctl/ioctl-number.txt
@@ -149,7 +149,6 @@ Code Seq#(hex) Include File Comments
'M' 01-03 drivers/scsi/megaraid/megaraid_sas.h
'M' 00-0F drivers/video/fsl-diu-fb.h conflict!
'N' 00-1F drivers/usb/scanner.h
-'N' 40-7F drivers/block/nvme.c
'O' 00-06 mtd/ubi-user.h UBI
'P' all linux/soundcard.h conflict!
'P' 60-6F sound/sscape_ioctl.h conflict!
diff --git a/trunk/Documentation/kbuild/makefiles.txt b/trunk/Documentation/kbuild/makefiles.txt
index ab0a984530d8..f47cdefb4d1e 100644
--- a/trunk/Documentation/kbuild/makefiles.txt
+++ b/trunk/Documentation/kbuild/makefiles.txt
@@ -33,15 +33,14 @@ This document describes the Linux kernel Makefiles.
=== 6 Architecture Makefiles
--- 6.1 Set variables to tweak the build to the architecture
- --- 6.2 Add prerequisites to archheaders:
- --- 6.3 Add prerequisites to archprepare:
- --- 6.4 List directories to visit when descending
- --- 6.5 Architecture-specific boot images
- --- 6.6 Building non-kbuild targets
- --- 6.7 Commands useful for building a boot image
- --- 6.8 Custom kbuild commands
- --- 6.9 Preprocessing linker scripts
- --- 6.10 Generic header files
+ --- 6.2 Add prerequisites to archprepare:
+ --- 6.3 List directories to visit when descending
+ --- 6.4 Architecture-specific boot images
+ --- 6.5 Building non-kbuild targets
+ --- 6.6 Commands useful for building a boot image
+ --- 6.7 Custom kbuild commands
+ --- 6.8 Preprocessing linker scripts
+ --- 6.9 Generic header files
=== 7 Kbuild syntax for exported headers
--- 7.1 header-y
@@ -253,7 +252,7 @@ more details, with real examples.
This will create a library lib.a based on delay.o. For kbuild to
actually recognize that there is a lib.a being built, the directory
shall be listed in libs-y.
- See also "6.4 List directories to visit when descending".
+ See also "6.3 List directories to visit when descending".
Use of lib-y is normally restricted to lib/ and arch/*/lib.
@@ -975,20 +974,7 @@ When kbuild executes, the following steps are followed (roughly):
$(KBUILD_ARFLAGS) set by the top level Makefile to "D" (deterministic
mode) if this option is supported by $(AR).
---- 6.2 Add prerequisites to archheaders:
-
- The archheaders: rule is used to generate header files that
- may be installed into user space by "make header_install" or
- "make headers_install_all". In order to support
- "make headers_install_all", this target has to be able to run
- on an unconfigured tree, or a tree configured for another
- architecture.
-
- It is run before "make archprepare" when run on the
- architecture itself.
-
-
---- 6.3 Add prerequisites to archprepare:
+--- 6.2 Add prerequisites to archprepare:
The archprepare: rule is used to list prerequisites that need to be
built before starting to descend down in the subdirectories.
@@ -1004,7 +990,7 @@ When kbuild executes, the following steps are followed (roughly):
generating offset header files.
---- 6.4 List directories to visit when descending
+--- 6.3 List directories to visit when descending
An arch Makefile cooperates with the top Makefile to define variables
which specify how to build the vmlinux file. Note that there is no
@@ -1033,7 +1019,7 @@ When kbuild executes, the following steps are followed (roughly):
drivers-$(CONFIG_OPROFILE) += arch/sparc64/oprofile/
---- 6.5 Architecture-specific boot images
+--- 6.4 Architecture-specific boot images
An arch Makefile specifies goals that take the vmlinux file, compress
it, wrap it in bootstrapping code, and copy the resulting files
@@ -1084,7 +1070,7 @@ When kbuild executes, the following steps are followed (roughly):
When "make" is executed without arguments, bzImage will be built.
---- 6.6 Building non-kbuild targets
+--- 6.5 Building non-kbuild targets
extra-y
@@ -1104,7 +1090,7 @@ When kbuild executes, the following steps are followed (roughly):
shall be built, but shall not be linked as part of built-in.o.
---- 6.7 Commands useful for building a boot image
+--- 6.6 Commands useful for building a boot image
Kbuild provides a few macros that are useful when building a
boot image.
@@ -1126,7 +1112,7 @@ When kbuild executes, the following steps are followed (roughly):
always be built.
Assignments to $(targets) are without $(obj)/ prefix.
if_changed may be used in conjunction with custom commands as
- defined in 6.8 "Custom kbuild commands".
+ defined in 6.7 "Custom kbuild commands".
Note: It is a typical mistake to forget the FORCE prerequisite.
Another common pitfall is that whitespace is sometimes
@@ -1185,7 +1171,7 @@ When kbuild executes, the following steps are followed (roughly):
$(obj)/%.dtb: $(src)/%.dts
$(call cmd,dtc)
---- 6.8 Custom kbuild commands
+--- 6.7 Custom kbuild commands
When kbuild is executing with KBUILD_VERBOSE=0, then only a shorthand
of a command is normally displayed.
@@ -1212,7 +1198,7 @@ When kbuild executes, the following steps are followed (roughly):
will be displayed with "make KBUILD_VERBOSE=0".
---- 6.9 Preprocessing linker scripts
+--- 6.8 Preprocessing linker scripts
When the vmlinux image is built, the linker script
arch/$(ARCH)/kernel/vmlinux.lds is used.
@@ -1242,7 +1228,7 @@ When kbuild executes, the following steps are followed (roughly):
The kbuild infrastructure for *lds file are used in several
architecture-specific files.
---- 6.10 Generic header files
+--- 6.9 Generic header files
The directory include/asm-generic contains the header files
that may be shared between individual architectures.
diff --git a/trunk/Documentation/kernel-parameters.txt b/trunk/Documentation/kernel-parameters.txt
index 033d4e69b43b..b29f3c416296 100644
--- a/trunk/Documentation/kernel-parameters.txt
+++ b/trunk/Documentation/kernel-parameters.txt
@@ -1059,11 +1059,6 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
By default, super page will be supported if Intel IOMMU
has the capability. With this option, super page will
not be supported.
-
- intel_idle.max_cstate= [KNL,HW,ACPI,X86]
- 0 disables intel_idle and fall back on acpi_idle.
- 1 to 6 specify maximum depth of C-state.
-
intremap= [X86-64, Intel-IOMMU]
on enable Interrupt Remapping (default)
off disable Interrupt Remapping
diff --git a/trunk/Documentation/scsi/ChangeLog.megaraid_sas b/trunk/Documentation/scsi/ChangeLog.megaraid_sas
index 57566bacb4c5..64adb98b181c 100644
--- a/trunk/Documentation/scsi/ChangeLog.megaraid_sas
+++ b/trunk/Documentation/scsi/ChangeLog.megaraid_sas
@@ -1,13 +1,3 @@
-Release Date : Fri. Jan 6, 2012 17:00:00 PST 2010 -
- (emaild-id:megaraidlinux@lsi.com)
- Adam Radford
-Current Version : 00.00.06.14-rc1
-Old Version : 00.00.06.12-rc1
- 1. Fix reglockFlags for degraded raid5/6 for MR 9360/9380.
- 2. Mask off flags in ioctl path to prevent memory scribble with older
- MegaCLI versions.
- 3. Remove poll_mode_io module paramater, sysfs node, and associated code.
--------------------------------------------------------------------------------
Release Date : Wed. Oct 5, 2011 17:00:00 PST 2010 -
(emaild-id:megaraidlinux@lsi.com)
Adam Radford
diff --git a/trunk/Documentation/scsi/LICENSE.qla4xxx b/trunk/Documentation/scsi/LICENSE.qla4xxx
index ab899591ecb7..494980e40491 100644
--- a/trunk/Documentation/scsi/LICENSE.qla4xxx
+++ b/trunk/Documentation/scsi/LICENSE.qla4xxx
@@ -1,11 +1,32 @@
Copyright (c) 2003-2011 QLogic Corporation
-QLogic Linux iSCSI Driver
+QLogic Linux iSCSI HBA Driver
This program includes a device driver for Linux 3.x.
You may modify and redistribute the device driver code under the
GNU General Public License (a copy of which is attached hereto as
Exhibit A) published by the Free Software Foundation (version 2).
+REGARDLESS OF WHAT LICENSING MECHANISM IS USED OR APPLICABLE,
+THIS PROGRAM IS PROVIDED BY QLOGIC CORPORATION "AS IS'' AND ANY
+EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
+PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR
+BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
+TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+
+USER ACKNOWLEDGES AND AGREES THAT USE OF THIS PROGRAM WILL NOT
+CREATE OR GIVE GROUNDS FOR A LICENSE BY IMPLICATION, ESTOPPEL, OR
+OTHERWISE IN ANY INTELLECTUAL PROPERTY RIGHTS (PATENT, COPYRIGHT,
+TRADE SECRET, MASK WORK, OR OTHER PROPRIETARY RIGHT) EMBODIED IN
+ANY OTHER QLOGIC HARDWARE OR SOFTWARE EITHER SOLELY OR IN
+COMBINATION WITH THIS PROGRAM.
+
EXHIBIT A
diff --git a/trunk/Documentation/target/tcm_mod_builder.py b/trunk/Documentation/target/tcm_mod_builder.py
index 6e21b8b52638..7ef9b843d529 100755
--- a/trunk/Documentation/target/tcm_mod_builder.py
+++ b/trunk/Documentation/target/tcm_mod_builder.py
@@ -230,9 +230,14 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += "#include \n"
buf += "#include \n\n"
buf += "#include \n"
- buf += "#include \n"
+ buf += "#include \n"
+ buf += "#include \n"
buf += "#include \n"
+ buf += "#include \n"
+ buf += "#include \n"
+ buf += "#include \n"
buf += "#include \n"
+ buf += "#include \n"
buf += "#include \n\n"
buf += "#include \"" + fabric_mod_name + "_base.h\"\n"
buf += "#include \"" + fabric_mod_name + "_fabric.h\"\n\n"
@@ -255,7 +260,7 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += " /* " + fabric_mod_name + "_parse_wwn(name, &wwpn, 1) < 0)\n"
buf += " return ERR_PTR(-EINVAL); */\n"
buf += " se_nacl_new = " + fabric_mod_name + "_alloc_fabric_acl(se_tpg);\n"
- buf += " if (!se_nacl_new)\n"
+ buf += " if (!(se_nacl_new))\n"
buf += " return ERR_PTR(-ENOMEM);\n"
buf += "//#warning FIXME: Hardcoded nexus depth in " + fabric_mod_name + "_make_nodeacl()\n"
buf += " nexus_depth = 1;\n"
@@ -303,7 +308,7 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += " if (strict_strtoul(name + 5, 10, &tpgt) || tpgt > UINT_MAX)\n"
buf += " return ERR_PTR(-EINVAL);\n\n"
buf += " tpg = kzalloc(sizeof(struct " + fabric_mod_name + "_tpg), GFP_KERNEL);\n"
- buf += " if (!tpg) {\n"
+ buf += " if (!(tpg)) {\n"
buf += " printk(KERN_ERR \"Unable to allocate struct " + fabric_mod_name + "_tpg\");\n"
buf += " return ERR_PTR(-ENOMEM);\n"
buf += " }\n"
@@ -339,7 +344,7 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += " /* if (" + fabric_mod_name + "_parse_wwn(name, &wwpn, 1) < 0)\n"
buf += " return ERR_PTR(-EINVAL); */\n\n"
buf += " " + fabric_mod_port + " = kzalloc(sizeof(struct " + fabric_mod_name + "_" + fabric_mod_port + "), GFP_KERNEL);\n"
- buf += " if (!" + fabric_mod_port + ") {\n"
+ buf += " if (!(" + fabric_mod_port + ")) {\n"
buf += " printk(KERN_ERR \"Unable to allocate struct " + fabric_mod_name + "_" + fabric_mod_port + "\");\n"
buf += " return ERR_PTR(-ENOMEM);\n"
buf += " }\n"
@@ -347,7 +352,7 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
if proto_ident == "FC" or proto_ident == "SAS":
buf += " " + fabric_mod_port + "->" + fabric_mod_port + "_wwpn = wwpn;\n"
- buf += " /* " + fabric_mod_name + "_format_wwn(&" + fabric_mod_port + "->" + fabric_mod_port + "_name[0], " + fabric_mod_name.upper() + "_NAMELEN, wwpn); */\n\n"
+ buf += " /* " + fabric_mod_name + "_format_wwn(&" + fabric_mod_port + "->" + fabric_mod_port + "_name[0], " + fabric_mod_name.upper() + "__NAMELEN, wwpn); */\n\n"
buf += " return &" + fabric_mod_port + "->" + fabric_mod_port + "_wwn;\n"
buf += "}\n\n"
buf += "static void " + fabric_mod_name + "_drop_" + fabric_mod_port + "(struct se_wwn *wwn)\n"
@@ -386,7 +391,8 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += " .tpg_alloc_fabric_acl = " + fabric_mod_name + "_alloc_fabric_acl,\n"
buf += " .tpg_release_fabric_acl = " + fabric_mod_name + "_release_fabric_acl,\n"
buf += " .tpg_get_inst_index = " + fabric_mod_name + "_tpg_get_inst_index,\n"
- buf += " .release_cmd = " + fabric_mod_name + "_release_cmd,\n"
+ buf += " .release_cmd_to_pool = " + fabric_mod_name + "_release_cmd,\n"
+ buf += " .release_cmd_direct = " + fabric_mod_name + "_release_cmd,\n"
buf += " .shutdown_session = " + fabric_mod_name + "_shutdown_session,\n"
buf += " .close_session = " + fabric_mod_name + "_close_session,\n"
buf += " .stop_session = " + fabric_mod_name + "_stop_session,\n"
@@ -399,12 +405,14 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += " .set_default_node_attributes = " + fabric_mod_name + "_set_default_node_attrs,\n"
buf += " .get_task_tag = " + fabric_mod_name + "_get_task_tag,\n"
buf += " .get_cmd_state = " + fabric_mod_name + "_get_cmd_state,\n"
+ buf += " .new_cmd_failure = " + fabric_mod_name + "_new_cmd_failure,\n"
buf += " .queue_data_in = " + fabric_mod_name + "_queue_data_in,\n"
buf += " .queue_status = " + fabric_mod_name + "_queue_status,\n"
buf += " .queue_tm_rsp = " + fabric_mod_name + "_queue_tm_rsp,\n"
buf += " .get_fabric_sense_len = " + fabric_mod_name + "_get_fabric_sense_len,\n"
buf += " .set_fabric_sense_len = " + fabric_mod_name + "_set_fabric_sense_len,\n"
buf += " .is_state_remove = " + fabric_mod_name + "_is_state_remove,\n"
+ buf += " .pack_lun = " + fabric_mod_name + "_pack_lun,\n"
buf += " /*\n"
buf += " * Setup function pointers for generic logic in target_core_fabric_configfs.c\n"
buf += " */\n"
@@ -431,9 +439,9 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += " * Register the top level struct config_item_type with TCM core\n"
buf += " */\n"
buf += " fabric = target_fabric_configfs_init(THIS_MODULE, \"" + fabric_mod_name[4:] + "\");\n"
- buf += " if (IS_ERR(fabric)) {\n"
+ buf += " if (!(fabric)) {\n"
buf += " printk(KERN_ERR \"target_fabric_configfs_init() failed\\n\");\n"
- buf += " return PTR_ERR(fabric);\n"
+ buf += " return -ENOMEM;\n"
buf += " }\n"
buf += " /*\n"
buf += " * Setup fabric->tf_ops from our local " + fabric_mod_name + "_ops\n"
@@ -467,9 +475,9 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += " printk(KERN_INFO \"" + fabric_mod_name.upper() + "[0] - Set fabric -> " + fabric_mod_name + "_fabric_configfs\\n\");\n"
buf += " return 0;\n"
buf += "};\n\n"
- buf += "static void __exit " + fabric_mod_name + "_deregister_configfs(void)\n"
+ buf += "static void " + fabric_mod_name + "_deregister_configfs(void)\n"
buf += "{\n"
- buf += " if (!" + fabric_mod_name + "_fabric_configfs)\n"
+ buf += " if (!(" + fabric_mod_name + "_fabric_configfs))\n"
buf += " return;\n\n"
buf += " target_fabric_configfs_deregister(" + fabric_mod_name + "_fabric_configfs);\n"
buf += " " + fabric_mod_name + "_fabric_configfs = NULL;\n"
@@ -484,15 +492,17 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += " return ret;\n\n"
buf += " return 0;\n"
buf += "};\n\n"
- buf += "static void __exit " + fabric_mod_name + "_exit(void)\n"
+ buf += "static void " + fabric_mod_name + "_exit(void)\n"
buf += "{\n"
buf += " " + fabric_mod_name + "_deregister_configfs();\n"
buf += "};\n\n"
+ buf += "#ifdef MODULE\n"
buf += "MODULE_DESCRIPTION(\"" + fabric_mod_name.upper() + " series fabric driver\");\n"
buf += "MODULE_LICENSE(\"GPL\");\n"
buf += "module_init(" + fabric_mod_name + "_init);\n"
buf += "module_exit(" + fabric_mod_name + "_exit);\n"
+ buf += "#endif\n"
ret = p.write(buf)
if ret:
@@ -504,7 +514,7 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
def tcm_mod_scan_fabric_ops(tcm_dir):
- fabric_ops_api = tcm_dir + "include/target/target_core_fabric.h"
+ fabric_ops_api = tcm_dir + "include/target/target_core_fabric_ops.h"
print "Using tcm_mod_scan_fabric_ops: " + fabric_ops_api
process_fo = 0;
@@ -569,7 +579,11 @@ def tcm_mod_dump_fabric_ops(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += "#include \n"
buf += "#include \n\n"
buf += "#include \n"
- buf += "#include \n"
+ buf += "#include \n"
+ buf += "#include \n"
+ buf += "#include \n"
+ buf += "#include \n"
+ buf += "#include \n"
buf += "#include \n\n"
buf += "#include \"" + fabric_mod_name + "_base.h\"\n"
buf += "#include \"" + fabric_mod_name + "_fabric.h\"\n\n"
@@ -774,7 +788,7 @@ def tcm_mod_dump_fabric_ops(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += "{\n"
buf += " struct " + fabric_mod_name + "_nacl *nacl;\n\n"
buf += " nacl = kzalloc(sizeof(struct " + fabric_mod_name + "_nacl), GFP_KERNEL);\n"
- buf += " if (!nacl) {\n"
+ buf += " if (!(nacl)) {\n"
buf += " printk(KERN_ERR \"Unable to alocate struct " + fabric_mod_name + "_nacl\\n\");\n"
buf += " return NULL;\n"
buf += " }\n\n"
@@ -801,7 +815,7 @@ def tcm_mod_dump_fabric_ops(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += "}\n\n"
bufi += "u32 " + fabric_mod_name + "_tpg_get_inst_index(struct se_portal_group *);\n"
- if re.search('\*release_cmd\)\(', fo):
+ if re.search('release_cmd_to_pool', fo):
buf += "void " + fabric_mod_name + "_release_cmd(struct se_cmd *se_cmd)\n"
buf += "{\n"
buf += " return;\n"
@@ -885,6 +899,13 @@ def tcm_mod_dump_fabric_ops(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += "}\n\n"
bufi += "int " + fabric_mod_name + "_get_cmd_state(struct se_cmd *);\n"
+ if re.search('new_cmd_failure\)\(', fo):
+ buf += "void " + fabric_mod_name + "_new_cmd_failure(struct se_cmd *se_cmd)\n"
+ buf += "{\n"
+ buf += " return;\n"
+ buf += "}\n\n"
+ bufi += "void " + fabric_mod_name + "_new_cmd_failure(struct se_cmd *);\n"
+
if re.search('queue_data_in\)\(', fo):
buf += "int " + fabric_mod_name + "_queue_data_in(struct se_cmd *se_cmd)\n"
buf += "{\n"
@@ -927,6 +948,15 @@ def tcm_mod_dump_fabric_ops(proto_ident, fabric_mod_dir_var, fabric_mod_name):
buf += "}\n\n"
bufi += "int " + fabric_mod_name + "_is_state_remove(struct se_cmd *);\n"
+ if re.search('pack_lun\)\(', fo):
+ buf += "u64 " + fabric_mod_name + "_pack_lun(unsigned int lun)\n"
+ buf += "{\n"
+ buf += " WARN_ON(lun >= 256);\n"
+ buf += " /* Caller wants this byte-swapped */\n"
+ buf += " return cpu_to_le64((lun & 0xff) << 8);\n"
+ buf += "}\n\n"
+ bufi += "u64 " + fabric_mod_name + "_pack_lun(unsigned int);\n"
+
ret = p.write(buf)
if ret:
diff --git a/trunk/Documentation/video4linux/v4l2-controls.txt b/trunk/Documentation/video4linux/v4l2-controls.txt
index e2492a9d1027..26aa0573933e 100644
--- a/trunk/Documentation/video4linux/v4l2-controls.txt
+++ b/trunk/Documentation/video4linux/v4l2-controls.txt
@@ -666,6 +666,27 @@ a control of this type whenever the first control belonging to a new control
class is added.
+Differences from the Spec
+=========================
+
+There are a few places where the framework acts slightly differently from the
+V4L2 Specification. Those differences are described in this section. We will
+have to see whether we need to adjust the spec or not.
+
+1) It is no longer required to have all controls contained in a
+v4l2_ext_control array be from the same control class. The framework will be
+able to handle any type of control in the array. You need to set ctrl_class
+to 0 in order to enable this. If ctrl_class is non-zero, then it will still
+check that all controls belong to that control class.
+
+If you set ctrl_class to 0 and count to 0, then it will only return an error
+if there are no controls at all.
+
+2) Clarified the way error_idx works. For get and set it will be equal to
+count if nothing was done yet. If it is less than count then only the controls
+up to error_idx-1 were successfully applied.
+
+
Proposals for Extensions
========================
diff --git a/trunk/MAINTAINERS b/trunk/MAINTAINERS
index 89b70df91f4f..2a90101309d1 100644
--- a/trunk/MAINTAINERS
+++ b/trunk/MAINTAINERS
@@ -745,7 +745,6 @@ M: Barry Song
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
S: Maintained
F: arch/arm/mach-prima2/
-F: drivers/dma/sirf-dma*
ARM/EBSA110 MACHINE SUPPORT
M: Russell King
@@ -1412,7 +1411,6 @@ F: net/ax25/
B43 WIRELESS DRIVER
M: Stefano Brivio
L: linux-wireless@vger.kernel.org
-L: b43-dev@lists.infradead.org (moderated for non-subscribers)
W: http://linuxwireless.org/en/users/Drivers/b43
S: Maintained
F: drivers/net/wireless/b43/
@@ -1589,13 +1587,6 @@ L: linux-scsi@vger.kernel.org
S: Supported
F: drivers/scsi/bnx2fc/
-BROADCOM SPECIFIC AMBA DRIVER (BCMA)
-M: Rafał Miłecki
-L: linux-wireless@vger.kernel.org
-S: Maintained
-F: drivers/bcma/
-F: include/linux/bcma/
-
BROCADE BFA FC SCSI DRIVER
M: Jing Huang
L: linux-scsi@vger.kernel.org
@@ -5855,7 +5846,7 @@ F: drivers/mmc/host/sdhci-spear.c
SECURITY SUBSYSTEM
M: James Morris
L: linux-security-module@vger.kernel.org (suggested Cc:)
-T: git git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security.git
+T: git git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6.git
W: http://security.wiki.kernel.org/
S: Supported
F: security/
@@ -6125,6 +6116,13 @@ S: Maintained
F: drivers/ssb/
F: include/linux/ssb/
+BROADCOM SPECIFIC AMBA DRIVER (BCMA)
+M: Rafał Miłecki
+L: linux-wireless@vger.kernel.org
+S: Maintained
+F: drivers/bcma/
+F: include/linux/bcma/
+
SONY VAIO CONTROL DEVICE DRIVER
M: Mattia Dongili
L: platform-driver-x86@vger.kernel.org
@@ -7200,7 +7198,7 @@ S: Maintained
F: drivers/net/vmxnet3/
VMware PVSCSI driver
-M: Arvind Kumar
+M: Alok Kataria
M: VMware PV-Drivers
L: linux-scsi@vger.kernel.org
S: Maintained
diff --git a/trunk/Makefile b/trunk/Makefile
index 156ac69c961e..adddd11c3b3b 100644
--- a/trunk/Makefile
+++ b/trunk/Makefile
@@ -312,7 +312,7 @@ endif
# If the user is running make -s (silent mode), suppress echoing of
# commands
-ifneq ($(filter s% -s%,$(MAKEFLAGS)),)
+ifneq ($(findstring s,$(MAKEFLAGS)),)
quiet=silent_
endif
@@ -442,7 +442,7 @@ asm-generic:
no-dot-config-targets := clean mrproper distclean \
cscope gtags TAGS tags help %docs check% coccicheck \
- include/linux/version.h headers_% archheaders \
+ include/linux/version.h headers_% \
kernelversion %src-pkg
config-targets := 0
@@ -979,7 +979,7 @@ prepare1: prepare2 include/linux/version.h include/generated/utsrelease.h \
include/config/auto.conf
$(cmd_crmodverdir)
-archprepare: archheaders prepare1 scripts_basic
+archprepare: prepare1 scripts_basic
prepare0: archprepare FORCE
$(Q)$(MAKE) $(build)=.
@@ -1046,11 +1046,8 @@ hdr-inst := -rR -f $(srctree)/scripts/Makefile.headersinst obj
# If we do an all arch process set dst to asm-$(hdr-arch)
hdr-dst = $(if $(KBUILD_HEADERS), dst=include/asm-$(hdr-arch), dst=include/asm)
-PHONY += archheaders
-archheaders:
-
PHONY += __headers
-__headers: include/linux/version.h scripts_basic asm-generic archheaders FORCE
+__headers: include/linux/version.h scripts_basic asm-generic FORCE
$(Q)$(MAKE) $(build)=scripts build_unifdef
PHONY += headers_install_all
diff --git a/trunk/arch/arm/boot/Makefile b/trunk/arch/arm/boot/Makefile
index fc871e719aae..5df26a9976a2 100644
--- a/trunk/arch/arm/boot/Makefile
+++ b/trunk/arch/arm/boot/Makefile
@@ -59,11 +59,9 @@ $(obj)/zImage: $(obj)/compressed/vmlinux FORCE
endif
-targets += $(dtb-y)
-
# Rule to build device tree blobs
-$(obj)/%.dtb: $(src)/dts/%.dts FORCE
- $(call if_changed_dep,dtc)
+$(obj)/%.dtb: $(src)/dts/%.dts
+ $(call cmd,dtc)
$(obj)/dtbs: $(addprefix $(obj)/, $(dtb-y))
diff --git a/trunk/arch/arm/include/asm/gpio.h b/trunk/arch/arm/include/asm/gpio.h
index c402e9b31f4c..7151753b0989 100644
--- a/trunk/arch/arm/include/asm/gpio.h
+++ b/trunk/arch/arm/include/asm/gpio.h
@@ -2,7 +2,7 @@
#define _ARCH_ARM_GPIO_H
#if CONFIG_ARCH_NR_GPIO > 0
-#define ARCH_NR_GPIOS CONFIG_ARCH_NR_GPIO
+#define ARCH_NR_GPIO CONFIG_ARCH_NR_GPIO
#endif
/* not all ARM platforms necessarily support this API ... */
diff --git a/trunk/arch/arm/include/asm/kprobes.h b/trunk/arch/arm/include/asm/kprobes.h
index f82ec22eeb11..feec86768f9c 100644
--- a/trunk/arch/arm/include/asm/kprobes.h
+++ b/trunk/arch/arm/include/asm/kprobes.h
@@ -24,6 +24,7 @@
#define MAX_INSN_SIZE 2
#define MAX_STACK_SIZE 64 /* 32 would probably be OK */
+#define regs_return_value(regs) ((regs)->ARM_r0)
#define flush_insn_slot(p) do { } while (0)
#define kretprobe_blacklist_size 0
diff --git a/trunk/arch/arm/include/asm/memblock.h b/trunk/arch/arm/include/asm/memblock.h
index 00ca5f92648e..b8da2e415e4e 100644
--- a/trunk/arch/arm/include/asm/memblock.h
+++ b/trunk/arch/arm/include/asm/memblock.h
@@ -6,6 +6,4 @@ struct machine_desc;
extern void arm_memblock_init(struct meminfo *, struct machine_desc *);
-phys_addr_t arm_memblock_steal(phys_addr_t size, phys_addr_t align);
-
#endif
diff --git a/trunk/arch/arm/include/asm/ptrace.h b/trunk/arch/arm/include/asm/ptrace.h
index 451808ba1211..96187ff58c24 100644
--- a/trunk/arch/arm/include/asm/ptrace.h
+++ b/trunk/arch/arm/include/asm/ptrace.h
@@ -189,11 +189,6 @@ static inline int valid_user_regs(struct pt_regs *regs)
return 0;
}
-static inline long regs_return_value(struct pt_regs *regs)
-{
- return regs->ARM_r0;
-}
-
#define instruction_pointer(regs) (regs)->ARM_pc
#ifdef CONFIG_SMP
diff --git a/trunk/arch/arm/include/asm/thread_info.h b/trunk/arch/arm/include/asm/thread_info.h
index d4c24d412a8d..0f30c3a78fc1 100644
--- a/trunk/arch/arm/include/asm/thread_info.h
+++ b/trunk/arch/arm/include/asm/thread_info.h
@@ -129,7 +129,6 @@ extern void vfp_flush_hwstate(struct thread_info *);
/*
* thread information flags:
* TIF_SYSCALL_TRACE - syscall trace active
- * TIF_SYSCAL_AUDIT - syscall auditing active
* TIF_SIGPENDING - signal pending
* TIF_NEED_RESCHED - rescheduling necessary
* TIF_NOTIFY_RESUME - callback before returning to user
@@ -140,7 +139,6 @@ extern void vfp_flush_hwstate(struct thread_info *);
#define TIF_NEED_RESCHED 1
#define TIF_NOTIFY_RESUME 2 /* callback before returning to user */
#define TIF_SYSCALL_TRACE 8
-#define TIF_SYSCALL_AUDIT 9
#define TIF_POLLING_NRFLAG 16
#define TIF_USING_IWMMXT 17
#define TIF_MEMDIE 18 /* is terminating due to OOM killer */
@@ -151,15 +149,11 @@ extern void vfp_flush_hwstate(struct thread_info *);
#define _TIF_NEED_RESCHED (1 << TIF_NEED_RESCHED)
#define _TIF_NOTIFY_RESUME (1 << TIF_NOTIFY_RESUME)
#define _TIF_SYSCALL_TRACE (1 << TIF_SYSCALL_TRACE)
-#define _TIF_SYSCALL_AUDIT (1 << TIF_SYSCALL_AUDIT)
#define _TIF_POLLING_NRFLAG (1 << TIF_POLLING_NRFLAG)
#define _TIF_USING_IWMMXT (1 << TIF_USING_IWMMXT)
#define _TIF_RESTORE_SIGMASK (1 << TIF_RESTORE_SIGMASK)
#define _TIF_SECCOMP (1 << TIF_SECCOMP)
-/* Checks for any syscall work in entry-common.S */
-#define _TIF_SYSCALL_WORK (_TIF_SYSCALL_TRACE | _TIF_SYSCALL_AUDIT)
-
/*
* Change these and you break ASM code in entry-common.S
*/
diff --git a/trunk/arch/arm/include/asm/unified.h b/trunk/arch/arm/include/asm/unified.h
index f5989f46b4d2..bc631161e9c6 100644
--- a/trunk/arch/arm/include/asm/unified.h
+++ b/trunk/arch/arm/include/asm/unified.h
@@ -37,8 +37,8 @@
#define THUMB(x...) x
#ifdef __ASSEMBLY__
#define W(instr) instr.w
-#define BSYM(sym) sym + 1
#endif
+#define BSYM(sym) sym + 1
#else /* !CONFIG_THUMB2_KERNEL */
@@ -49,8 +49,8 @@
#define THUMB(x...)
#ifdef __ASSEMBLY__
#define W(instr) instr
-#define BSYM(sym) sym
#endif
+#define BSYM(sym) sym
#endif /* CONFIG_THUMB2_KERNEL */
diff --git a/trunk/arch/arm/kernel/entry-common.S b/trunk/arch/arm/kernel/entry-common.S
index 520889cf1b5b..b2a27b6b0046 100644
--- a/trunk/arch/arm/kernel/entry-common.S
+++ b/trunk/arch/arm/kernel/entry-common.S
@@ -87,7 +87,7 @@ ENTRY(ret_from_fork)
get_thread_info tsk
ldr r1, [tsk, #TI_FLAGS] @ check for syscall tracing
mov why, #1
- tst r1, #_TIF_SYSCALL_WORK @ are we tracing syscalls?
+ tst r1, #_TIF_SYSCALL_TRACE @ are we tracing syscalls?
beq ret_slow_syscall
mov r1, sp
mov r0, #1 @ trace exit [IP = 1]
@@ -443,7 +443,7 @@ ENTRY(vector_swi)
1:
#endif
- tst r10, #_TIF_SYSCALL_WORK @ are we tracing syscalls?
+ tst r10, #_TIF_SYSCALL_TRACE @ are we tracing syscalls?
bne __sys_trace
cmp scno, #NR_syscalls @ check upper syscall limit
diff --git a/trunk/arch/arm/kernel/head.S b/trunk/arch/arm/kernel/head.S
index 6d5791144066..14e277d2ff91 100644
--- a/trunk/arch/arm/kernel/head.S
+++ b/trunk/arch/arm/kernel/head.S
@@ -99,14 +99,6 @@ ENTRY(stext)
THUMB( it eq ) @ force fixup-able long branch encoding
beq __error_p @ yes, error 'p'
-#ifdef CONFIG_ARM_LPAE
- mrc p15, 0, r3, c0, c1, 4 @ read ID_MMFR0
- and r3, r3, #0xf @ extract VMSA support
- cmp r3, #5 @ long-descriptor translation table format?
- THUMB( it lo ) @ force fixup-able long branch encoding
- blo __error_p @ only classic page table format
-#endif
-
#ifndef CONFIG_XIP_KERNEL
adr r3, 2f
ldmia r3, {r4, r8}
diff --git a/trunk/arch/arm/kernel/ptrace.c b/trunk/arch/arm/kernel/ptrace.c
index e1d5e1929fbd..483727ad6892 100644
--- a/trunk/arch/arm/kernel/ptrace.c
+++ b/trunk/arch/arm/kernel/ptrace.c
@@ -906,6 +906,11 @@ asmlinkage int syscall_trace(int why, struct pt_regs *regs, int scno)
{
unsigned long ip;
+ if (!test_thread_flag(TIF_SYSCALL_TRACE))
+ return scno;
+ if (!(current->ptrace & PT_PTRACED))
+ return scno;
+
/*
* Save IP. IP is used to denote syscall entry/exit:
* IP = 0 -> entry, = 1 -> exit
@@ -913,17 +918,6 @@ asmlinkage int syscall_trace(int why, struct pt_regs *regs, int scno)
ip = regs->ARM_ip;
regs->ARM_ip = why;
- if (!ip)
- audit_syscall_exit(regs);
- else
- audit_syscall_entry(AUDIT_ARCH_ARMEB, scno, regs->ARM_r0,
- regs->ARM_r1, regs->ARM_r2, regs->ARM_r3);
-
- if (!test_thread_flag(TIF_SYSCALL_TRACE))
- return scno;
- if (!(current->ptrace & PT_PTRACED))
- return scno;
-
current_thread_info()->syscall = scno;
/* the 0x80 provides a way for the tracing parent to distinguish
diff --git a/trunk/arch/arm/mach-ep93xx/include/mach/dma.h b/trunk/arch/arm/mach-ep93xx/include/mach/dma.h
index e82c642fa53c..46d4d876e6fb 100644
--- a/trunk/arch/arm/mach-ep93xx/include/mach/dma.h
+++ b/trunk/arch/arm/mach-ep93xx/include/mach/dma.h
@@ -37,7 +37,7 @@
*/
struct ep93xx_dma_data {
int port;
- enum dma_transfer_direction direction;
+ enum dma_data_direction direction;
const char *name;
};
@@ -80,14 +80,14 @@ static inline bool ep93xx_dma_chan_is_m2p(struct dma_chan *chan)
* channel supports given DMA direction. Only M2P channels have such
* limitation, for M2M channels the direction is configurable.
*/
-static inline enum dma_transfer_direction
+static inline enum dma_data_direction
ep93xx_dma_chan_direction(struct dma_chan *chan)
{
if (!ep93xx_dma_chan_is_m2p(chan))
return DMA_NONE;
/* even channels are for TX, odd for RX */
- return (chan->chan_id % 2 == 0) ? DMA_MEM_TO_DEV : DMA_DEV_TO_MEM;
+ return (chan->chan_id % 2 == 0) ? DMA_TO_DEVICE : DMA_FROM_DEVICE;
}
#endif /* __ASM_ARCH_DMA_H */
diff --git a/trunk/arch/arm/mach-exynos/headsmp.S b/trunk/arch/arm/mach-exynos/headsmp.S
index 5364d4bfa8bc..3cdeb3647542 100644
--- a/trunk/arch/arm/mach-exynos/headsmp.S
+++ b/trunk/arch/arm/mach-exynos/headsmp.S
@@ -36,8 +36,6 @@ pen: ldr r7, [r6]
* should now contain the SVC stack for this core
*/
b secondary_startup
-ENDPROC(exynos4_secondary_startup)
- .align 2
1: .long .
.long pen_release
diff --git a/trunk/arch/arm/mach-exynos/mach-origen.c b/trunk/arch/arm/mach-exynos/mach-origen.c
index 0679b8ad2d1e..2b11e046d391 100644
--- a/trunk/arch/arm/mach-exynos/mach-origen.c
+++ b/trunk/arch/arm/mach-exynos/mach-origen.c
@@ -597,8 +597,7 @@ static struct s3c_fb_pd_win origen_fb_win0 = {
static struct s3c_fb_platdata origen_lcd_pdata __initdata = {
.win[0] = &origen_fb_win0,
.vidcon0 = VIDCON0_VIDOUT_RGB | VIDCON0_PNRMODE_RGB,
- .vidcon1 = VIDCON1_INV_HSYNC | VIDCON1_INV_VSYNC |
- VIDCON1_INV_VCLK,
+ .vidcon1 = VIDCON1_INV_HSYNC | VIDCON1_INV_VSYNC,
.setup_gpio = exynos4_fimd0_gpio_setup_24bpp,
};
diff --git a/trunk/arch/arm/mach-exynos/platsmp.c b/trunk/arch/arm/mach-exynos/platsmp.c
index 683aec786b78..60bc45e3e709 100644
--- a/trunk/arch/arm/mach-exynos/platsmp.c
+++ b/trunk/arch/arm/mach-exynos/platsmp.c
@@ -24,6 +24,7 @@
#include
#include
#include
+#include
#include
#include
@@ -136,7 +137,7 @@ int __cpuinit boot_secondary(unsigned int cpu, struct task_struct *idle)
while (time_before(jiffies, timeout)) {
smp_rmb();
- __raw_writel(virt_to_phys(exynos4_secondary_startup),
+ __raw_writel(BSYM(virt_to_phys(exynos4_secondary_startup)),
CPU1_BOOT_REG);
gic_raise_softirq(cpumask_of(cpu), 1);
@@ -191,6 +192,6 @@ void __init platform_smp_prepare_cpus(unsigned int max_cpus)
* until it receives a soft interrupt, and then the
* secondary CPU branches to this address.
*/
- __raw_writel(virt_to_phys(exynos4_secondary_startup),
+ __raw_writel(BSYM(virt_to_phys(exynos4_secondary_startup)),
CPU1_BOOT_REG);
}
diff --git a/trunk/arch/arm/mach-highbank/highbank.c b/trunk/arch/arm/mach-highbank/highbank.c
index 7afbe1e55beb..804c4a55f803 100644
--- a/trunk/arch/arm/mach-highbank/highbank.c
+++ b/trunk/arch/arm/mach-highbank/highbank.c
@@ -25,6 +25,7 @@
#include
#include
+#include
#include
#include
#include
@@ -75,7 +76,7 @@ void highbank_set_cpu_jump(int cpu, void *jump_addr)
#ifdef CONFIG_SMP
cpu = cpu_logical_map(cpu);
#endif
- writel(virt_to_phys(jump_addr), HB_JUMP_TABLE_VIRT(cpu));
+ writel(BSYM(virt_to_phys(jump_addr)), HB_JUMP_TABLE_VIRT(cpu));
__cpuc_flush_dcache_area(HB_JUMP_TABLE_VIRT(cpu), 16);
outer_clean_range(HB_JUMP_TABLE_PHYS(cpu),
HB_JUMP_TABLE_PHYS(cpu) + 15);
diff --git a/trunk/arch/arm/mach-imx/mach-mx31_3ds.c b/trunk/arch/arm/mach-imx/mach-mx31_3ds.c
index 4d1aab154400..89c33258639f 100644
--- a/trunk/arch/arm/mach-imx/mach-mx31_3ds.c
+++ b/trunk/arch/arm/mach-imx/mach-mx31_3ds.c
@@ -36,7 +36,6 @@
#include
#include
#include
-#include
#include
#include
#include
@@ -755,8 +754,10 @@ static struct sys_timer mx31_3ds_timer = {
static void __init mx31_3ds_reserve(void)
{
/* reserve MX31_3DS_CAMERA_BUF_SIZE bytes for mx3-camera */
- mx3_camera_base = arm_memblock_steal(MX31_3DS_CAMERA_BUF_SIZE,
+ mx3_camera_base = memblock_alloc(MX31_3DS_CAMERA_BUF_SIZE,
MX31_3DS_CAMERA_BUF_SIZE);
+ memblock_free(mx3_camera_base, MX31_3DS_CAMERA_BUF_SIZE);
+ memblock_remove(mx3_camera_base, MX31_3DS_CAMERA_BUF_SIZE);
}
MACHINE_START(MX31_3DS, "Freescale MX31PDK (3DS)")
diff --git a/trunk/arch/arm/mach-imx/mach-mx31moboard.c b/trunk/arch/arm/mach-imx/mach-mx31moboard.c
index f225262b5c38..b95981dacb2b 100644
--- a/trunk/arch/arm/mach-imx/mach-mx31moboard.c
+++ b/trunk/arch/arm/mach-imx/mach-mx31moboard.c
@@ -41,7 +41,6 @@
#include
#include
#include
-#include
#include
#include
#include
@@ -585,8 +584,10 @@ struct sys_timer mx31moboard_timer = {
static void __init mx31moboard_reserve(void)
{
/* reserve 4 MiB for mx3-camera */
- mx3_camera_base = arm_memblock_steal(MX3_CAMERA_BUF_SIZE,
+ mx3_camera_base = memblock_alloc(MX3_CAMERA_BUF_SIZE,
MX3_CAMERA_BUF_SIZE);
+ memblock_free(mx3_camera_base, MX3_CAMERA_BUF_SIZE);
+ memblock_remove(mx3_camera_base, MX3_CAMERA_BUF_SIZE);
}
MACHINE_START(MX31MOBOARD, "EPFL Mobots mx31moboard")
diff --git a/trunk/arch/arm/mach-imx/mach-pcm037.c b/trunk/arch/arm/mach-imx/mach-pcm037.c
index e48854b9d990..d7e151669ed3 100644
--- a/trunk/arch/arm/mach-imx/mach-pcm037.c
+++ b/trunk/arch/arm/mach-imx/mach-pcm037.c
@@ -39,7 +39,6 @@
#include
#include
#include
-#include
#include
#include
#include
@@ -681,8 +680,10 @@ struct sys_timer pcm037_timer = {
static void __init pcm037_reserve(void)
{
/* reserve 4 MiB for mx3-camera */
- mx3_camera_base = arm_memblock_steal(MX3_CAMERA_BUF_SIZE,
+ mx3_camera_base = memblock_alloc(MX3_CAMERA_BUF_SIZE,
MX3_CAMERA_BUF_SIZE);
+ memblock_free(mx3_camera_base, MX3_CAMERA_BUF_SIZE);
+ memblock_remove(mx3_camera_base, MX3_CAMERA_BUF_SIZE);
}
MACHINE_START(PCM037, "Phytec Phycore pcm037")
diff --git a/trunk/arch/arm/mach-imx/src.c b/trunk/arch/arm/mach-imx/src.c
index 29bd1243781e..4bde04f99e38 100644
--- a/trunk/arch/arm/mach-imx/src.c
+++ b/trunk/arch/arm/mach-imx/src.c
@@ -15,6 +15,7 @@
#include
#include
#include
+#include
#define SRC_SCR 0x000
#define SRC_GPR1 0x020
@@ -42,7 +43,7 @@ void imx_enable_cpu(int cpu, bool enable)
void imx_set_cpu_jump(int cpu, void *jump_addr)
{
cpu = cpu_logical_map(cpu);
- writel_relaxed(virt_to_phys(jump_addr),
+ writel_relaxed(BSYM(virt_to_phys(jump_addr)),
src_base + SRC_GPR1 + cpu * 8);
}
diff --git a/trunk/arch/arm/mach-msm/headsmp.S b/trunk/arch/arm/mach-msm/headsmp.S
index bcd5af223dea..0c631a9f8647 100644
--- a/trunk/arch/arm/mach-msm/headsmp.S
+++ b/trunk/arch/arm/mach-msm/headsmp.S
@@ -34,7 +34,6 @@ pen: ldr r7, [r6]
* should now contain the SVC stack for this core
*/
b secondary_startup
-ENDPROC(msm_secondary_startup)
.align
1: .long .
diff --git a/trunk/arch/arm/mach-msm/vreg.c b/trunk/arch/arm/mach-msm/vreg.c
index bd66ed04d6dc..a9103bc6615f 100644
--- a/trunk/arch/arm/mach-msm/vreg.c
+++ b/trunk/arch/arm/mach-msm/vreg.c
@@ -19,7 +19,6 @@
#include
#include
#include
-#include
#include
#include
diff --git a/trunk/arch/arm/mach-omap2/Kconfig b/trunk/arch/arm/mach-omap2/Kconfig
index a8ba7b96dcd1..904bd1dfcd2e 100644
--- a/trunk/arch/arm/mach-omap2/Kconfig
+++ b/trunk/arch/arm/mach-omap2/Kconfig
@@ -366,8 +366,8 @@ config OMAP3_SDRC_AC_TIMING
going on could result in system crashes;
config OMAP4_ERRATA_I688
- bool "OMAP4 errata: Async Bridge Corruption (BROKEN)"
- depends on ARCH_OMAP4 && BROKEN
+ bool "OMAP4 errata: Async Bridge Corruption"
+ depends on ARCH_OMAP4
select ARCH_HAS_BARRIERS
help
If a data is stalled inside asynchronous bridge because of back
diff --git a/trunk/arch/arm/mach-omap2/devices.c b/trunk/arch/arm/mach-omap2/devices.c
index 0b510ad01a00..46dfd1ae8f71 100644
--- a/trunk/arch/arm/mach-omap2/devices.c
+++ b/trunk/arch/arm/mach-omap2/devices.c
@@ -28,6 +28,7 @@
#include
#include
#include
+#include
#include
#include
#include
@@ -127,10 +128,6 @@ static struct platform_device omap2cam_device = {
};
#endif
-#if defined(CONFIG_IOMMU_API)
-
-#include
-
static struct resource omap3isp_resources[] = {
{
.start = OMAP3430_ISP_BASE,
@@ -227,15 +224,6 @@ int omap3_init_camera(struct isp_platform_data *pdata)
return platform_device_register(&omap3isp_device);
}
-#else /* !CONFIG_IOMMU_API */
-
-int omap3_init_camera(struct isp_platform_data *pdata)
-{
- return 0;
-}
-
-#endif
-
static inline void omap_init_camera(void)
{
#if defined(CONFIG_VIDEO_OMAP2) || defined(CONFIG_VIDEO_OMAP2_MODULE)
diff --git a/trunk/arch/arm/mach-omap2/omap-secure.c b/trunk/arch/arm/mach-omap2/omap-secure.c
index d8f8ef40290f..69f3c72d959b 100644
--- a/trunk/arch/arm/mach-omap2/omap-secure.c
+++ b/trunk/arch/arm/mach-omap2/omap-secure.c
@@ -16,7 +16,6 @@
#include
#include
-#include
#include
@@ -58,10 +57,20 @@ u32 omap_secure_dispatcher(u32 idx, u32 flag, u32 nargs, u32 arg1, u32 arg2,
/* Allocate the memory to save secure ram */
int __init omap_secure_ram_reserve_memblock(void)
{
+ phys_addr_t paddr;
u32 size = OMAP_SECURE_RAM_STORAGE;
size = ALIGN(size, SZ_1M);
- omap_secure_memblock_base = arm_memblock_steal(size, SZ_1M);
+ paddr = memblock_alloc(size, SZ_1M);
+ if (!paddr) {
+ pr_err("%s: failed to reserve %x bytes\n",
+ __func__, size);
+ return -ENOMEM;
+ }
+ memblock_free(paddr, size);
+ memblock_remove(paddr, size);
+
+ omap_secure_memblock_base = paddr;
return 0;
}
diff --git a/trunk/arch/arm/mach-omap2/omap4-common.c b/trunk/arch/arm/mach-omap2/omap4-common.c
index 40a8fbc07e4b..bc16c818c6b7 100644
--- a/trunk/arch/arm/mach-omap2/omap4-common.c
+++ b/trunk/arch/arm/mach-omap2/omap4-common.c
@@ -20,7 +20,6 @@
#include
#include
#include
-#include
#include
#include
@@ -62,8 +61,13 @@ static int __init omap_barriers_init(void)
return -ENODEV;
size = ALIGN(PAGE_SIZE, SZ_1M);
- paddr = arm_memblock_steal(size, SZ_1M);
-
+ paddr = memblock_alloc(size, SZ_1M);
+ if (!paddr) {
+ pr_err("%s: failed to reserve 4 Kbytes\n", __func__);
+ return -ENOMEM;
+ }
+ memblock_free(paddr, size);
+ memblock_remove(paddr, size);
dram_io_desc[0].virtual = OMAP4_DRAM_BARRIER_VA;
dram_io_desc[0].pfn = __phys_to_pfn(paddr);
dram_io_desc[0].length = size;
diff --git a/trunk/arch/arm/mach-picoxcell/time.c b/trunk/arch/arm/mach-picoxcell/time.c
index 2ecba6743b8e..6c89cf8ab22e 100644
--- a/trunk/arch/arm/mach-picoxcell/time.c
+++ b/trunk/arch/arm/mach-picoxcell/time.c
@@ -67,7 +67,7 @@ static void picoxcell_add_clocksource(struct device_node *source_timer)
static void __iomem *sched_io_base;
-static u32 picoxcell_read_sched_clock(void)
+unsigned u32 notrace picoxcell_read_sched_clock(void)
{
return __raw_readl(sched_io_base);
}
diff --git a/trunk/arch/arm/mach-realview/platsmp.c b/trunk/arch/arm/mach-realview/platsmp.c
index 17c878ddbc70..e83c654a58d0 100644
--- a/trunk/arch/arm/mach-realview/platsmp.c
+++ b/trunk/arch/arm/mach-realview/platsmp.c
@@ -17,6 +17,7 @@
#include
#include
#include
+#include
#include
#include
@@ -74,6 +75,6 @@ void __init platform_smp_prepare_cpus(unsigned int max_cpus)
* until it receives a soft interrupt, and then the
* secondary CPU branches to this address.
*/
- __raw_writel(virt_to_phys(versatile_secondary_startup),
+ __raw_writel(BSYM(virt_to_phys(versatile_secondary_startup)),
__io_address(REALVIEW_SYS_FLAGSSET));
}
diff --git a/trunk/arch/arm/mach-s3c64xx/include/mach/crag6410.h b/trunk/arch/arm/mach-s3c64xx/include/mach/crag6410.h
index 4cb2f951f1e9..5d55ab018b6b 100644
--- a/trunk/arch/arm/mach-s3c64xx/include/mach/crag6410.h
+++ b/trunk/arch/arm/mach-s3c64xx/include/mach/crag6410.h
@@ -21,6 +21,5 @@
#define CODEC_GPIO_BASE (GPIO_BOARD_START + 8)
#define GLENFARCLAS_PMIC_GPIO_BASE (GPIO_BOARD_START + 32)
#define BANFF_PMIC_GPIO_BASE (GPIO_BOARD_START + 64)
-#define MMGPIO_GPIO_BASE (GPIO_BOARD_START + 96)
#endif
diff --git a/trunk/arch/arm/mach-s3c64xx/mach-crag6410.c b/trunk/arch/arm/mach-s3c64xx/mach-crag6410.c
index 8077f650eb0e..1cc91d794c97 100644
--- a/trunk/arch/arm/mach-s3c64xx/mach-crag6410.c
+++ b/trunk/arch/arm/mach-s3c64xx/mach-crag6410.c
@@ -260,7 +260,6 @@ static struct platform_device crag6410_dm9k_device = {
static struct resource crag6410_mmgpio_resource[] = {
[0] = {
- .name = "dat",
.start = S3C64XX_PA_XM0CSN4 + 1,
.end = S3C64XX_PA_XM0CSN4 + 1,
.flags = IORESOURCE_MEM,
@@ -273,7 +272,7 @@ static struct platform_device crag6410_mmgpio = {
.resource = crag6410_mmgpio_resource,
.num_resources = ARRAY_SIZE(crag6410_mmgpio_resource),
.dev.platform_data = &(struct bgpio_pdata) {
- .base = MMGPIO_GPIO_BASE,
+ .base = -1,
},
};
@@ -329,6 +328,7 @@ static struct platform_device wallvdd_device = {
static struct platform_device *crag6410_devices[] __initdata = {
&s3c_device_hsmmc0,
+ &s3c_device_hsmmc1,
&s3c_device_hsmmc2,
&s3c_device_i2c0,
&s3c_device_i2c1,
@@ -355,7 +355,7 @@ static struct platform_device *crag6410_devices[] __initdata = {
static struct pca953x_platform_data crag6410_pca_data = {
.gpio_base = PCA935X_GPIO_BASE,
- .irq_base = -1,
+ .irq_base = 0,
};
/* VDDARM is controlled by DVS1 connected to GPK(0) */
@@ -683,6 +683,12 @@ static struct s3c_sdhci_platdata crag6410_hsmmc2_pdata = {
.cd_type = S3C_SDHCI_CD_PERMANENT,
};
+static struct s3c_sdhci_platdata crag6410_hsmmc1_pdata = {
+ .max_width = 4,
+ .cd_type = S3C_SDHCI_CD_GPIO,
+ .ext_cd_gpio = S3C64XX_GPF(11),
+};
+
static void crag6410_cfg_sdhci0(struct platform_device *dev, int width)
{
/* Set all the necessary GPG pins to special-function 2 */
@@ -717,6 +723,7 @@ static void __init crag6410_machine_init(void)
gpio_direction_output(S3C64XX_GPF(10), 1);
s3c_sdhci0_set_platdata(&crag6410_hsmmc0_pdata);
+ s3c_sdhci1_set_platdata(&crag6410_hsmmc1_pdata);
s3c_sdhci2_set_platdata(&crag6410_hsmmc2_pdata);
s3c_i2c0_set_platdata(&i2c0_pdata);
diff --git a/trunk/arch/arm/mach-s3c64xx/pm.c b/trunk/arch/arm/mach-s3c64xx/pm.c
index 7d3e81b9dd06..055dac90e0e2 100644
--- a/trunk/arch/arm/mach-s3c64xx/pm.c
+++ b/trunk/arch/arm/mach-s3c64xx/pm.c
@@ -346,10 +346,23 @@ int __init s3c64xx_pm_init(void)
static __init int s3c64xx_pm_initcall(void)
{
+ u32 val;
+
pm_cpu_prep = s3c64xx_pm_prepare;
pm_cpu_sleep = s3c64xx_cpu_suspend;
pm_uart_udivslot = 1;
+ /*
+ * Unconditionally disable power domains that contain only
+ * blocks which have no mainline driver support.
+ */
+ val = __raw_readl(S3C64XX_NORMAL_CFG);
+ val &= ~(S3C64XX_NORMALCFG_DOMAIN_G_ON |
+ S3C64XX_NORMALCFG_DOMAIN_V_ON |
+ S3C64XX_NORMALCFG_DOMAIN_I_ON |
+ S3C64XX_NORMALCFG_DOMAIN_P_ON);
+ __raw_writel(val, S3C64XX_NORMAL_CFG);
+
#ifdef CONFIG_S3C_PM_DEBUG_LED_SMDK
gpio_request(S3C64XX_GPN(12), "DEBUG_LED0");
gpio_request(S3C64XX_GPN(13), "DEBUG_LED1");
diff --git a/trunk/arch/arm/mach-sa1100/assabet.c b/trunk/arch/arm/mach-sa1100/assabet.c
index ebafe8aa8956..5bc6b3837b20 100644
--- a/trunk/arch/arm/mach-sa1100/assabet.c
+++ b/trunk/arch/arm/mach-sa1100/assabet.c
@@ -280,7 +280,7 @@ static void __init map_sa1100_gpio_regs( void )
int prot = PMD_TYPE_SECT | PMD_SECT_AP_WRITE | PMD_DOMAIN(DOMAIN_IO);
pmd_t *pmd;
- pmd = pmd_offset(pud_offset(pgd_offset_k(virt), virt), virt);
+ pmd = pmd_offset(pgd_offset_k(virt), virt);
*pmd = __pmd(phys | prot);
flush_pmd_entry(pmd);
}
diff --git a/trunk/arch/arm/mach-shmobile/pm-sh7372.c b/trunk/arch/arm/mach-shmobile/pm-sh7372.c
index fcf8b1761aef..77b8fc12fc2f 100644
--- a/trunk/arch/arm/mach-shmobile/pm-sh7372.c
+++ b/trunk/arch/arm/mach-shmobile/pm-sh7372.c
@@ -276,7 +276,7 @@ static int sh7372_a3sp_suspend(void)
* Serial consoles make use of SCIF hardware located in A3SP,
* keep such power domain on if "no_console_suspend" is set.
*/
- return console_suspend_enabled ? 0 : -EBUSY;
+ return console_suspend_enabled ? -EBUSY : 0;
}
struct sh7372_pm_domain sh7372_a3sp = {
diff --git a/trunk/arch/arm/mach-shmobile/setup-sh7372.c b/trunk/arch/arm/mach-shmobile/setup-sh7372.c
index 6fcf304d3cdf..1ea89be63e29 100644
--- a/trunk/arch/arm/mach-shmobile/setup-sh7372.c
+++ b/trunk/arch/arm/mach-shmobile/setup-sh7372.c
@@ -445,39 +445,31 @@ static const struct sh_dmae_slave_config sh7372_dmae_slaves[] = {
},
};
-#define SH7372_CHCLR 0x220
-
static const struct sh_dmae_channel sh7372_dmae_channels[] = {
{
.offset = 0,
.dmars = 0,
.dmars_bit = 0,
- .chclr_offset = SH7372_CHCLR + 0,
}, {
.offset = 0x10,
.dmars = 0,
.dmars_bit = 8,
- .chclr_offset = SH7372_CHCLR + 0x10,
}, {
.offset = 0x20,
.dmars = 4,
.dmars_bit = 0,
- .chclr_offset = SH7372_CHCLR + 0x20,
}, {
.offset = 0x30,
.dmars = 4,
.dmars_bit = 8,
- .chclr_offset = SH7372_CHCLR + 0x30,
}, {
.offset = 0x50,
.dmars = 8,
.dmars_bit = 0,
- .chclr_offset = SH7372_CHCLR + 0x50,
}, {
.offset = 0x60,
.dmars = 8,
.dmars_bit = 8,
- .chclr_offset = SH7372_CHCLR + 0x60,
}
};
@@ -495,7 +487,6 @@ static struct sh_dmae_pdata dma_platform_data = {
.ts_shift = ts_shift,
.ts_shift_num = ARRAY_SIZE(ts_shift),
.dmaor_init = DMAOR_DME,
- .chclr_present = 1,
};
/* Resource order important! */
@@ -503,7 +494,7 @@ static struct resource sh7372_dmae0_resources[] = {
{
/* Channel registers and DMAOR */
.start = 0xfe008020,
- .end = 0xfe00828f,
+ .end = 0xfe00808f,
.flags = IORESOURCE_MEM,
},
{
@@ -531,7 +522,7 @@ static struct resource sh7372_dmae1_resources[] = {
{
/* Channel registers and DMAOR */
.start = 0xfe018020,
- .end = 0xfe01828f,
+ .end = 0xfe01808f,
.flags = IORESOURCE_MEM,
},
{
@@ -559,7 +550,7 @@ static struct resource sh7372_dmae2_resources[] = {
{
/* Channel registers and DMAOR */
.start = 0xfe028020,
- .end = 0xfe02828f,
+ .end = 0xfe02808f,
.flags = IORESOURCE_MEM,
},
{
diff --git a/trunk/arch/arm/mach-ux500/headsmp.S b/trunk/arch/arm/mach-ux500/headsmp.S
index 08da5589bcd8..64fa451edcfd 100644
--- a/trunk/arch/arm/mach-ux500/headsmp.S
+++ b/trunk/arch/arm/mach-ux500/headsmp.S
@@ -32,8 +32,6 @@ pen: ldr r7, [r6]
* should now contain the SVC stack for this core
*/
b secondary_startup
-ENDPROC(u8500_secondary_startup)
- .align 2
1: .long .
.long pen_release
diff --git a/trunk/arch/arm/mach-vexpress/platsmp.c b/trunk/arch/arm/mach-vexpress/platsmp.c
index 124ffb169093..2b5f7ac001a3 100644
--- a/trunk/arch/arm/mach-vexpress/platsmp.c
+++ b/trunk/arch/arm/mach-vexpress/platsmp.c
@@ -13,6 +13,8 @@
#include
#include
+#include
+
#include
#define V2M_PA_CS7 0x10000000
@@ -44,6 +46,6 @@ void __init platform_smp_prepare_cpus(unsigned int max_cpus)
* secondary CPU branches to this address.
*/
writel(~0, MMIO_P2V(V2M_SYS_FLAGSCLR));
- writel(virt_to_phys(versatile_secondary_startup),
+ writel(BSYM(virt_to_phys(versatile_secondary_startup)),
MMIO_P2V(V2M_SYS_FLAGSSET));
}
diff --git a/trunk/arch/arm/mach-w90x900/clksel.c b/trunk/arch/arm/mach-w90x900/clksel.c
index 06d867dce551..3de4a5211c3b 100644
--- a/trunk/arch/arm/mach-w90x900/clksel.c
+++ b/trunk/arch/arm/mach-w90x900/clksel.c
@@ -48,7 +48,7 @@ static void clock_source_select(const char *dev_id, unsigned int clkval)
offset = ATAOFFSET;
else if (strcmp(dev_id, "nuc900-lcd") == 0)
offset = LCDOFFSET;
- else if (strcmp(dev_id, "nuc900-ac97") == 0)
+ else if (strcmp(dev_id, "nuc900-audio") == 0)
offset = AUDOFFSET;
else
offset = CPUOFFSET;
diff --git a/trunk/arch/arm/mach-w90x900/cpu.c b/trunk/arch/arm/mach-w90x900/cpu.c
index 9a0661992909..604e1db266e8 100644
--- a/trunk/arch/arm/mach-w90x900/cpu.c
+++ b/trunk/arch/arm/mach-w90x900/cpu.c
@@ -79,7 +79,7 @@ static DEFINE_CLK(timer4, 23);
static struct clk_lookup nuc900_clkregs[] = {
DEF_CLKLOOK(&clk_lcd, "nuc900-lcd", NULL),
- DEF_CLKLOOK(&clk_audio, "nuc900-ac97", NULL),
+ DEF_CLKLOOK(&clk_audio, "nuc900-audio", NULL),
DEF_CLKLOOK(&clk_fmi, "nuc900-fmi", NULL),
DEF_CLKLOOK(&clk_ms, "nuc900-fmi", "MS"),
DEF_CLKLOOK(&clk_sd, "nuc900-fmi", "SD"),
diff --git a/trunk/arch/arm/mach-w90x900/dev.c b/trunk/arch/arm/mach-w90x900/dev.c
index 78110befb7a9..5b0c38abacc1 100644
--- a/trunk/arch/arm/mach-w90x900/dev.c
+++ b/trunk/arch/arm/mach-w90x900/dev.c
@@ -501,8 +501,8 @@ static struct resource nuc900_ac97_resource[] = {
};
-struct platform_device nuc900_device_ac97 = {
- .name = "nuc900-ac97",
+struct platform_device nuc900_device_audio = {
+ .name = "nuc900-audio",
.id = -1,
.num_resources = ARRAY_SIZE(nuc900_ac97_resource),
.resource = nuc900_ac97_resource,
@@ -523,7 +523,7 @@ static struct platform_device *nuc900_public_dev[] __initdata = {
&nuc900_device_emc,
&nuc900_device_spi,
&nuc900_device_wdt,
- &nuc900_device_ac97,
+ &nuc900_device_audio,
};
/* Provide adding specific CPU platform devices API */
diff --git a/trunk/arch/arm/mach-w90x900/mfp.c b/trunk/arch/arm/mach-w90x900/mfp.c
index c58d142b8a46..9dd74612bb87 100644
--- a/trunk/arch/arm/mach-w90x900/mfp.c
+++ b/trunk/arch/arm/mach-w90x900/mfp.c
@@ -155,7 +155,7 @@ void mfp_set_groupg(struct device *dev, const char *subname)
} else if (strcmp(dev_id, "nuc900-i2c1") == 0) {
mfpen &= ~(GPIOG2TO3);
mfpen |= ENI2C1;/*enable i2c1*/
- } else if (strcmp(dev_id, "nuc900-ac97") == 0) {
+ } else if (strcmp(dev_id, "nuc900-audio") == 0) {
mfpen &= ~(GPIOG22TO23);
mfpen |= ENAC97;/*enable AC97*/
} else if (strcmp(dev_id, "nuc900-mmc-port1") == 0) {
diff --git a/trunk/arch/arm/mm/init.c b/trunk/arch/arm/mm/init.c
index 6ec1226fc62d..e34ea8adc1f9 100644
--- a/trunk/arch/arm/mm/init.c
+++ b/trunk/arch/arm/mm/init.c
@@ -22,7 +22,6 @@
#include
#include
-#include
#include
#include
#include
@@ -308,21 +307,6 @@ static void arm_memory_present(void)
}
#endif
-static bool arm_memblock_steal_permitted = true;
-
-phys_addr_t arm_memblock_steal(phys_addr_t size, phys_addr_t align)
-{
- phys_addr_t phys;
-
- BUG_ON(!arm_memblock_steal_permitted);
-
- phys = memblock_alloc(size, align);
- memblock_free(phys, size);
- memblock_remove(phys, size);
-
- return phys;
-}
-
void __init arm_memblock_init(struct meminfo *mi, struct machine_desc *mdesc)
{
int i;
@@ -365,7 +349,6 @@ void __init arm_memblock_init(struct meminfo *mi, struct machine_desc *mdesc)
if (mdesc->reserve)
mdesc->reserve();
- arm_memblock_steal_permitted = false;
memblock_allow_resize();
memblock_dump_all();
}
diff --git a/trunk/arch/arm/plat-mxc/include/mach/mx3fb.h b/trunk/arch/arm/plat-mxc/include/mach/mx3fb.h
index fdbe60001542..ac24c5c4bc83 100644
--- a/trunk/arch/arm/plat-mxc/include/mach/mx3fb.h
+++ b/trunk/arch/arm/plat-mxc/include/mach/mx3fb.h
@@ -22,20 +22,6 @@
#define FB_SYNC_SWAP_RGB 0x04000000
#define FB_SYNC_CLK_SEL_EN 0x02000000
-/*
- * Specify the way your display is connected. The IPU can arbitrarily
- * map the internal colors to the external data lines. We only support
- * the following mappings at the moment.
- */
-enum disp_data_mapping {
- /* blue -> d[0..5], green -> d[6..11], red -> d[12..17] */
- IPU_DISP_DATA_MAPPING_RGB666,
- /* blue -> d[0..4], green -> d[5..10], red -> d[11..15] */
- IPU_DISP_DATA_MAPPING_RGB565,
- /* blue -> d[0..7], green -> d[8..15], red -> d[16..23] */
- IPU_DISP_DATA_MAPPING_RGB888,
-};
-
/**
* struct mx3fb_platform_data - mx3fb platform data
*
@@ -47,7 +33,6 @@ struct mx3fb_platform_data {
const char *name;
const struct fb_videomode *mode;
int num_modes;
- enum disp_data_mapping disp_data_fmt;
};
#endif
diff --git a/trunk/arch/arm/plat-nomadik/include/plat/ste_dma40.h b/trunk/arch/arm/plat-nomadik/include/plat/ste_dma40.h
index fd0ee84c45d1..685c78716d95 100644
--- a/trunk/arch/arm/plat-nomadik/include/plat/ste_dma40.h
+++ b/trunk/arch/arm/plat-nomadik/include/plat/ste_dma40.h
@@ -113,8 +113,7 @@ struct stedma40_half_channel_info {
* @dst_dev_type: Dst device type
* @src_info: Parameters for dst half channel
* @dst_info: Parameters for dst half channel
- * @use_fixed_channel: if true, use physical channel specified by phy_channel
- * @phy_channel: physical channel to use, only if use_fixed_channel is true
+ *
*
* This structure has to be filled by the client drivers.
* It is recommended to do all dma configurations for clients in the machine.
@@ -130,9 +129,6 @@ struct stedma40_chan_cfg {
int dst_dev_type;
struct stedma40_half_channel_info src_info;
struct stedma40_half_channel_info dst_info;
-
- bool use_fixed_channel;
- int phy_channel;
};
/**
@@ -157,7 +153,6 @@ struct stedma40_platform_data {
struct stedma40_chan_cfg *memcpy_conf_phy;
struct stedma40_chan_cfg *memcpy_conf_log;
int disabled_channels[STEDMA40_MAX_PHYS];
- bool use_esram_lcla;
};
#ifdef CONFIG_STE_DMA40
@@ -192,7 +187,7 @@ static inline struct
dma_async_tx_descriptor *stedma40_slave_mem(struct dma_chan *chan,
dma_addr_t addr,
unsigned int size,
- enum dma_transfer_direction direction,
+ enum dma_data_direction direction,
unsigned long flags)
{
struct scatterlist sg;
@@ -214,7 +209,7 @@ static inline struct
dma_async_tx_descriptor *stedma40_slave_mem(struct dma_chan *chan,
dma_addr_t addr,
unsigned int size,
- enum dma_transfer_direction direction,
+ enum dma_data_direction direction,
unsigned long flags)
{
return NULL;
diff --git a/trunk/arch/arm/plat-omap/devices.c b/trunk/arch/arm/plat-omap/devices.c
index 60278f47c0bd..19719329a47b 100644
--- a/trunk/arch/arm/plat-omap/devices.c
+++ b/trunk/arch/arm/plat-omap/devices.c
@@ -20,7 +20,6 @@
#include
#include
#include
-#include
#include
#include
@@ -165,12 +164,14 @@ void __init omap_dsp_reserve_sdram_memblock(void)
if (!size)
return;
- paddr = arm_memblock_steal(size, SZ_1M);
+ paddr = memblock_alloc(size, SZ_1M);
if (!paddr) {
pr_err("%s: failed to reserve %x bytes\n",
__func__, size);
return;
}
+ memblock_free(paddr, size);
+ memblock_remove(paddr, size);
omap_dsp_phys_mempool_base = paddr;
}
diff --git a/trunk/arch/arm/plat-s3c24xx/cpu.c b/trunk/arch/arm/plat-s3c24xx/cpu.c
index 21f1fda8b661..1121df13e15f 100644
--- a/trunk/arch/arm/plat-s3c24xx/cpu.c
+++ b/trunk/arch/arm/plat-s3c24xx/cpu.c
@@ -38,6 +38,8 @@
#include
#include
+#include
+
#include
#include
diff --git a/trunk/arch/arm/plat-samsung/dma-ops.c b/trunk/arch/arm/plat-samsung/dma-ops.c
index 0747c77a2fd5..2cded872f22b 100644
--- a/trunk/arch/arm/plat-samsung/dma-ops.c
+++ b/trunk/arch/arm/plat-samsung/dma-ops.c
@@ -37,14 +37,14 @@ static unsigned samsung_dmadev_request(enum dma_ch dma_ch,
(void *)dma_ch;
chan = dma_request_channel(mask, pl330_filter, filter_param);
- if (info->direction == DMA_DEV_TO_MEM) {
+ if (info->direction == DMA_FROM_DEVICE) {
memset(&slave_config, 0, sizeof(struct dma_slave_config));
slave_config.direction = info->direction;
slave_config.src_addr = info->fifo;
slave_config.src_addr_width = info->width;
slave_config.src_maxburst = 1;
dmaengine_slave_config(chan, &slave_config);
- } else if (info->direction == DMA_MEM_TO_DEV) {
+ } else if (info->direction == DMA_TO_DEVICE) {
memset(&slave_config, 0, sizeof(struct dma_slave_config));
slave_config.direction = info->direction;
slave_config.dst_addr = info->fifo;
diff --git a/trunk/arch/arm/plat-samsung/include/plat/dma-ops.h b/trunk/arch/arm/plat-samsung/include/plat/dma-ops.h
index 71a6827c7706..22eafc310bd7 100644
--- a/trunk/arch/arm/plat-samsung/include/plat/dma-ops.h
+++ b/trunk/arch/arm/plat-samsung/include/plat/dma-ops.h
@@ -14,11 +14,10 @@
#define __SAMSUNG_DMA_OPS_H_ __FILE__
#include
-#include
struct samsung_dma_prep_info {
enum dma_transaction_type cap;
- enum dma_transfer_direction direction;
+ enum dma_data_direction direction;
dma_addr_t buf;
unsigned long period;
unsigned long len;
@@ -28,7 +27,7 @@ struct samsung_dma_prep_info {
struct samsung_dma_info {
enum dma_transaction_type cap;
- enum dma_transfer_direction direction;
+ enum dma_data_direction direction;
enum dma_slave_buswidth width;
dma_addr_t fifo;
struct s3c2410_dma_client *client;
diff --git a/trunk/arch/arm/plat-samsung/include/plat/dma.h b/trunk/arch/arm/plat-samsung/include/plat/dma.h
index 7b02143ccd9a..b9061128abde 100644
--- a/trunk/arch/arm/plat-samsung/include/plat/dma.h
+++ b/trunk/arch/arm/plat-samsung/include/plat/dma.h
@@ -10,9 +10,6 @@
* published by the Free Software Foundation.
*/
-#ifndef __PLAT_DMA_H
-#define __PLAT_DMA_H
-
#include
enum s3c2410_dma_buffresult {
@@ -125,6 +122,5 @@ extern int s3c2410_dma_getposition(enum dma_ch channel,
extern int s3c2410_dma_set_opfn(enum dma_ch, s3c2410_dma_opfn_t rtn);
extern int s3c2410_dma_set_buffdone_fn(enum dma_ch, s3c2410_dma_cbfn_t rtn);
-#include
-#endif
+#include
diff --git a/trunk/arch/arm/plat-samsung/include/plat/s3c64xx-spi.h b/trunk/arch/arm/plat-samsung/include/plat/s3c64xx-spi.h
index fa95e9a00972..aea68b60ef98 100644
--- a/trunk/arch/arm/plat-samsung/include/plat/s3c64xx-spi.h
+++ b/trunk/arch/arm/plat-samsung/include/plat/s3c64xx-spi.h
@@ -11,8 +11,6 @@
#ifndef __S3C64XX_PLAT_SPI_H
#define __S3C64XX_PLAT_SPI_H
-struct platform_device;
-
/**
* struct s3c64xx_spi_csinfo - ChipSelect description
* @fb_delay: Slave specific feedback delay.
diff --git a/trunk/arch/arm/plat-versatile/headsmp.S b/trunk/arch/arm/plat-versatile/headsmp.S
index dd703ef09b8d..d397a1fb2f54 100644
--- a/trunk/arch/arm/plat-versatile/headsmp.S
+++ b/trunk/arch/arm/plat-versatile/headsmp.S
@@ -38,4 +38,3 @@ pen: ldr r7, [r6]
.align
1: .long .
.long pen_release
-ENDPROC(versatile_secondary_startup)
diff --git a/trunk/arch/ia64/include/asm/ptrace.h b/trunk/arch/ia64/include/asm/ptrace.h
index 68c98f5b3ca6..f5cb27614e35 100644
--- a/trunk/arch/ia64/include/asm/ptrace.h
+++ b/trunk/arch/ia64/include/asm/ptrace.h
@@ -246,18 +246,7 @@ static inline unsigned long user_stack_pointer(struct pt_regs *regs)
return regs->ar_bspstore;
}
-static inline int is_syscall_success(struct pt_regs *regs)
-{
- return regs->r10 != -1;
-}
-
-static inline long regs_return_value(struct pt_regs *regs)
-{
- if (is_syscall_success(regs))
- return regs->r8;
- else
- return -regs->r8;
-}
+#define regs_return_value(regs) ((regs)->r8)
/* Conserve space in histogram by encoding slot bits in address
* bits 2 and 3 rather than bits 0 and 1.
diff --git a/trunk/arch/ia64/kernel/acpi.c b/trunk/arch/ia64/kernel/acpi.c
index 5207035dc061..bfb4d01e0e51 100644
--- a/trunk/arch/ia64/kernel/acpi.c
+++ b/trunk/arch/ia64/kernel/acpi.c
@@ -429,24 +429,22 @@ static u32 __devinitdata pxm_flag[PXM_FLAG_LEN];
static struct acpi_table_slit __initdata *slit_table;
cpumask_t early_cpu_possible_map = CPU_MASK_NONE;
-static int __init
-get_processor_proximity_domain(struct acpi_srat_cpu_affinity *pa)
+static int get_processor_proximity_domain(struct acpi_srat_cpu_affinity *pa)
{
int pxm;
pxm = pa->proximity_domain_lo;
- if (ia64_platform_is("sn2") || acpi_srat_revision >= 2)
+ if (ia64_platform_is("sn2"))
pxm += pa->proximity_domain_hi[0] << 8;
return pxm;
}
-static int __init
-get_memory_proximity_domain(struct acpi_srat_mem_affinity *ma)
+static int get_memory_proximity_domain(struct acpi_srat_mem_affinity *ma)
{
int pxm;
pxm = ma->proximity_domain;
- if (!ia64_platform_is("sn2") && acpi_srat_revision <= 1)
+ if (!ia64_platform_is("sn2"))
pxm &= 0xff;
return pxm;
diff --git a/trunk/arch/ia64/kernel/ptrace.c b/trunk/arch/ia64/kernel/ptrace.c
index dad91661ddf9..8848f43d819e 100644
--- a/trunk/arch/ia64/kernel/ptrace.c
+++ b/trunk/arch/ia64/kernel/ptrace.c
@@ -1246,8 +1246,15 @@ syscall_trace_enter (long arg0, long arg1, long arg2, long arg3,
if (test_thread_flag(TIF_RESTORE_RSE))
ia64_sync_krbs();
+ if (unlikely(current->audit_context)) {
+ long syscall;
+ int arch;
- audit_syscall_entry(AUDIT_ARCH_IA64, regs.r15, arg0, arg1, arg2, arg3);
+ syscall = regs.r15;
+ arch = AUDIT_ARCH_IA64;
+
+ audit_syscall_entry(arch, syscall, arg0, arg1, arg2, arg3);
+ }
return 0;
}
@@ -1261,7 +1268,14 @@ syscall_trace_leave (long arg0, long arg1, long arg2, long arg3,
{
int step;
- audit_syscall_exit(®s);
+ if (unlikely(current->audit_context)) {
+ int success = AUDITSC_RESULT(regs.r10);
+ long result = regs.r8;
+
+ if (success != AUDITSC_SUCCESS)
+ result = -result;
+ audit_syscall_exit(success, result);
+ }
step = test_thread_flag(TIF_SINGLESTEP);
if (step || test_thread_flag(TIF_SYSCALL_TRACE))
diff --git a/trunk/arch/microblaze/boot/Makefile b/trunk/arch/microblaze/boot/Makefile
index 0c796cf81586..4c4e58ef0cb6 100644
--- a/trunk/arch/microblaze/boot/Makefile
+++ b/trunk/arch/microblaze/boot/Makefile
@@ -53,6 +53,6 @@ $(obj)/simpleImage.%: vmlinux FORCE
DTC_FLAGS := -p 1024
$(obj)/%.dtb: $(src)/dts/%.dts FORCE
- $(call if_changed_dep,dtc)
+ $(call cmd,dtc)
clean-files += *.dtb simpleImage.*.unstrip linux.bin.ub
diff --git a/trunk/arch/microblaze/include/asm/ptrace.h b/trunk/arch/microblaze/include/asm/ptrace.h
index 94e92c805859..816bee64b196 100644
--- a/trunk/arch/microblaze/include/asm/ptrace.h
+++ b/trunk/arch/microblaze/include/asm/ptrace.h
@@ -61,11 +61,6 @@ struct pt_regs {
#define instruction_pointer(regs) ((regs)->pc)
#define profile_pc(regs) instruction_pointer(regs)
-static inline long regs_return_value(struct pt_regs *regs)
-{
- return regs->r3;
-}
-
#else /* __KERNEL__ */
/* pt_regs offsets used by gdbserver etc in ptrace syscalls */
diff --git a/trunk/arch/microblaze/kernel/ptrace.c b/trunk/arch/microblaze/kernel/ptrace.c
index 6eb2aa927d89..043cb58f9c44 100644
--- a/trunk/arch/microblaze/kernel/ptrace.c
+++ b/trunk/arch/microblaze/kernel/ptrace.c
@@ -147,8 +147,10 @@ asmlinkage long do_syscall_trace_enter(struct pt_regs *regs)
*/
ret = -1L;
- audit_syscall_entry(EM_MICROBLAZE, regs->r12, regs->r5, regs->r6,
- regs->r7, regs->r8);
+ if (unlikely(current->audit_context))
+ audit_syscall_entry(EM_MICROBLAZE, regs->r12,
+ regs->r5, regs->r6,
+ regs->r7, regs->r8);
return ret ?: regs->r12;
}
@@ -157,7 +159,8 @@ asmlinkage void do_syscall_trace_leave(struct pt_regs *regs)
{
int step;
- audit_syscall_exit(regs);
+ if (unlikely(current->audit_context))
+ audit_syscall_exit(AUDITSC_RESULT(regs->r3), regs->r3);
step = test_thread_flag(TIF_SINGLESTEP);
if (step || test_thread_flag(TIF_SYSCALL_TRACE))
diff --git a/trunk/arch/microblaze/kernel/setup.c b/trunk/arch/microblaze/kernel/setup.c
index d4fc1a971779..604cd9dd1333 100644
--- a/trunk/arch/microblaze/kernel/setup.c
+++ b/trunk/arch/microblaze/kernel/setup.c
@@ -26,7 +26,6 @@
#include
#include
#include
-#include
#include
#include
#include
@@ -227,23 +226,5 @@ static int __init setup_bus_notifier(void)
return 0;
}
-arch_initcall(setup_bus_notifier);
-
-static DEFINE_PER_CPU(struct cpu, cpu_devices);
-
-static int __init topology_init(void)
-{
- int i, ret;
-
- for_each_present_cpu(i) {
- struct cpu *c = &per_cpu(cpu_devices, i);
- ret = register_cpu(c, i);
- if (ret)
- printk(KERN_WARNING "topology_init: register_cpu %d "
- "failed (%d)\n", i, ret);
- }
-
- return 0;
-}
-subsys_initcall(topology_init);
+arch_initcall(setup_bus_notifier);
diff --git a/trunk/arch/mips/include/asm/ptrace.h b/trunk/arch/mips/include/asm/ptrace.h
index 4b7f5252d2fd..7b99c670e478 100644
--- a/trunk/arch/mips/include/asm/ptrace.h
+++ b/trunk/arch/mips/include/asm/ptrace.h
@@ -137,19 +137,7 @@ extern int ptrace_set_watch_regs(struct task_struct *child,
*/
#define user_mode(regs) (((regs)->cp0_status & KU_MASK) == KU_USER)
-static inline int is_syscall_success(struct pt_regs *regs)
-{
- return !regs->regs[7];
-}
-
-static inline long regs_return_value(struct pt_regs *regs)
-{
- if (is_syscall_success(regs))
- return regs->regs[2];
- else
- return -regs->regs[2];
-}
-
+#define regs_return_value(_regs) ((_regs)->regs[2])
#define instruction_pointer(regs) ((regs)->cp0_epc)
#define profile_pc(regs) instruction_pointer(regs)
diff --git a/trunk/arch/mips/kernel/ptrace.c b/trunk/arch/mips/kernel/ptrace.c
index 7786b608d932..4e6ea1ffad46 100644
--- a/trunk/arch/mips/kernel/ptrace.c
+++ b/trunk/arch/mips/kernel/ptrace.c
@@ -560,9 +560,10 @@ asmlinkage void syscall_trace_enter(struct pt_regs *regs)
}
out:
- audit_syscall_entry(audit_arch(), regs->regs[2],
- regs->regs[4], regs->regs[5],
- regs->regs[6], regs->regs[7]);
+ if (unlikely(current->audit_context))
+ audit_syscall_entry(audit_arch(), regs->regs[2],
+ regs->regs[4], regs->regs[5],
+ regs->regs[6], regs->regs[7]);
}
/*
@@ -571,7 +572,9 @@ asmlinkage void syscall_trace_enter(struct pt_regs *regs)
*/
asmlinkage void syscall_trace_leave(struct pt_regs *regs)
{
- audit_syscall_exit(regs);
+ if (unlikely(current->audit_context))
+ audit_syscall_exit(AUDITSC_RESULT(regs->regs[7]),
+ -regs->regs[2]);
if (!(current->ptrace & PT_PTRACED))
return;
diff --git a/trunk/arch/openrisc/boot/Makefile b/trunk/arch/openrisc/boot/Makefile
index 09958358601a..98ca185097a5 100644
--- a/trunk/arch/openrisc/boot/Makefile
+++ b/trunk/arch/openrisc/boot/Makefile
@@ -11,5 +11,5 @@ clean-files := *.dtb.S
#DTC_FLAGS ?= -p 1024
-$(obj)/%.dtb: $(src)/dts/%.dts FORCE
- $(call if_changed_dep,dtc)
+$(obj)/%.dtb: $(src)/dts/%.dts
+ $(call cmd,dtc)
diff --git a/trunk/arch/powerpc/boot/Makefile b/trunk/arch/powerpc/boot/Makefile
index 8844a17ce8ed..15986e70799c 100644
--- a/trunk/arch/powerpc/boot/Makefile
+++ b/trunk/arch/powerpc/boot/Makefile
@@ -345,8 +345,8 @@ $(obj)/treeImage.%: vmlinux $(obj)/%.dtb $(wrapperbits)
$(call if_changed,wrap,treeboot-$*,,$(obj)/$*.dtb)
# Rule to build device tree blobs
-$(obj)/%.dtb: $(src)/dts/%.dts FORCE
- $(call if_changed_dep,dtc)
+$(obj)/%.dtb: $(src)/dts/%.dts
+ $(call cmd,dtc)
# If there isn't a platform selected then just strip the vmlinux.
ifeq (,$(image-y))
diff --git a/trunk/arch/powerpc/include/asm/ptrace.h b/trunk/arch/powerpc/include/asm/ptrace.h
index 78a205162fd7..48223f9b8728 100644
--- a/trunk/arch/powerpc/include/asm/ptrace.h
+++ b/trunk/arch/powerpc/include/asm/ptrace.h
@@ -86,18 +86,7 @@ struct pt_regs {
#define instruction_pointer(regs) ((regs)->nip)
#define user_stack_pointer(regs) ((regs)->gpr[1])
#define kernel_stack_pointer(regs) ((regs)->gpr[1])
-static inline int is_syscall_success(struct pt_regs *regs)
-{
- return !(regs->ccr & 0x10000000);
-}
-
-static inline long regs_return_value(struct pt_regs *regs)
-{
- if (is_syscall_success(regs))
- return regs->gpr[3];
- else
- return -regs->gpr[3];
-}
+#define regs_return_value(regs) ((regs)->gpr[3])
#ifdef CONFIG_SMP
extern unsigned long profile_pc(struct pt_regs *regs);
diff --git a/trunk/arch/powerpc/kernel/ptrace.c b/trunk/arch/powerpc/kernel/ptrace.c
index 5b43325402bc..5de73dbd15c7 100644
--- a/trunk/arch/powerpc/kernel/ptrace.c
+++ b/trunk/arch/powerpc/kernel/ptrace.c
@@ -1724,20 +1724,22 @@ long do_syscall_trace_enter(struct pt_regs *regs)
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_enter(regs, regs->gpr[0]);
+ if (unlikely(current->audit_context)) {
#ifdef CONFIG_PPC64
- if (!is_32bit_task())
- audit_syscall_entry(AUDIT_ARCH_PPC64,
- regs->gpr[0],
- regs->gpr[3], regs->gpr[4],
- regs->gpr[5], regs->gpr[6]);
- else
+ if (!is_32bit_task())
+ audit_syscall_entry(AUDIT_ARCH_PPC64,
+ regs->gpr[0],
+ regs->gpr[3], regs->gpr[4],
+ regs->gpr[5], regs->gpr[6]);
+ else
#endif
- audit_syscall_entry(AUDIT_ARCH_PPC,
- regs->gpr[0],
- regs->gpr[3] & 0xffffffff,
- regs->gpr[4] & 0xffffffff,
- regs->gpr[5] & 0xffffffff,
- regs->gpr[6] & 0xffffffff);
+ audit_syscall_entry(AUDIT_ARCH_PPC,
+ regs->gpr[0],
+ regs->gpr[3] & 0xffffffff,
+ regs->gpr[4] & 0xffffffff,
+ regs->gpr[5] & 0xffffffff,
+ regs->gpr[6] & 0xffffffff);
+ }
return ret ?: regs->gpr[0];
}
@@ -1746,7 +1748,9 @@ void do_syscall_trace_leave(struct pt_regs *regs)
{
int step;
- audit_syscall_exit(regs);
+ if (unlikely(current->audit_context))
+ audit_syscall_exit((regs->ccr&0x10000000)?AUDITSC_FAILURE:AUDITSC_SUCCESS,
+ regs->result);
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_exit(regs, regs->result);
diff --git a/trunk/arch/s390/include/asm/ptrace.h b/trunk/arch/s390/include/asm/ptrace.h
index aeb77f017985..56da355678f4 100644
--- a/trunk/arch/s390/include/asm/ptrace.h
+++ b/trunk/arch/s390/include/asm/ptrace.h
@@ -541,13 +541,9 @@ struct user_regs_struct
#define user_mode(regs) (((regs)->psw.mask & PSW_MASK_PSTATE) != 0)
#define instruction_pointer(regs) ((regs)->psw.addr & PSW_ADDR_INSN)
#define user_stack_pointer(regs)((regs)->gprs[15])
+#define regs_return_value(regs)((regs)->gprs[2])
#define profile_pc(regs) instruction_pointer(regs)
-static inline long regs_return_value(struct pt_regs *regs)
-{
- return regs->gprs[2];
-}
-
int regs_query_register_offset(const char *name);
const char *regs_query_register_name(unsigned int offset);
unsigned long regs_get_register(struct pt_regs *regs, unsigned int offset);
diff --git a/trunk/arch/s390/kernel/ptrace.c b/trunk/arch/s390/kernel/ptrace.c
index 9d82ed4bcb27..573bc29551ef 100644
--- a/trunk/arch/s390/kernel/ptrace.c
+++ b/trunk/arch/s390/kernel/ptrace.c
@@ -740,17 +740,20 @@ asmlinkage long do_syscall_trace_enter(struct pt_regs *regs)
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_enter(regs, regs->gprs[2]);
- audit_syscall_entry(is_compat_task() ?
- AUDIT_ARCH_S390 : AUDIT_ARCH_S390X,
- regs->gprs[2], regs->orig_gpr2,
- regs->gprs[3], regs->gprs[4],
- regs->gprs[5]);
+ if (unlikely(current->audit_context))
+ audit_syscall_entry(is_compat_task() ?
+ AUDIT_ARCH_S390 : AUDIT_ARCH_S390X,
+ regs->gprs[2], regs->orig_gpr2,
+ regs->gprs[3], regs->gprs[4],
+ regs->gprs[5]);
return ret ?: regs->gprs[2];
}
asmlinkage void do_syscall_trace_exit(struct pt_regs *regs)
{
- audit_syscall_exit(regs);
+ if (unlikely(current->audit_context))
+ audit_syscall_exit(AUDITSC_RESULT(regs->gprs[2]),
+ regs->gprs[2]);
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_exit(regs, regs->gprs[2]);
diff --git a/trunk/arch/sh/include/asm/ptrace_32.h b/trunk/arch/sh/include/asm/ptrace_32.h
index 2d3e906aa722..6c2239cca1a2 100644
--- a/trunk/arch/sh/include/asm/ptrace_32.h
+++ b/trunk/arch/sh/include/asm/ptrace_32.h
@@ -76,10 +76,7 @@ struct pt_dspregs {
#ifdef __KERNEL__
#define MAX_REG_OFFSET offsetof(struct pt_regs, tra)
-static inline long regs_return_value(struct pt_regs *regs)
-{
- return regs->regs[0];
-}
+#define regs_return_value(_regs) ((_regs)->regs[0])
#endif /* __KERNEL__ */
diff --git a/trunk/arch/sh/include/asm/ptrace_64.h b/trunk/arch/sh/include/asm/ptrace_64.h
index eb3fcceaf64b..bf9be7764d69 100644
--- a/trunk/arch/sh/include/asm/ptrace_64.h
+++ b/trunk/arch/sh/include/asm/ptrace_64.h
@@ -13,10 +13,7 @@ struct pt_regs {
#ifdef __KERNEL__
#define MAX_REG_OFFSET offsetof(struct pt_regs, tregs[7])
-static inline long regs_return_value(struct pt_regs *regs)
-{
- return regs->regs[3];
-}
+#define regs_return_value(_regs) ((_regs)->regs[3])
#endif /* __KERNEL__ */
diff --git a/trunk/arch/sh/kernel/ptrace_32.c b/trunk/arch/sh/kernel/ptrace_32.c
index a3e651563763..92b3c276339a 100644
--- a/trunk/arch/sh/kernel/ptrace_32.c
+++ b/trunk/arch/sh/kernel/ptrace_32.c
@@ -518,9 +518,10 @@ asmlinkage long do_syscall_trace_enter(struct pt_regs *regs)
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_enter(regs, regs->regs[0]);
- audit_syscall_entry(audit_arch(), regs->regs[3],
- regs->regs[4], regs->regs[5],
- regs->regs[6], regs->regs[7]);
+ if (unlikely(current->audit_context))
+ audit_syscall_entry(audit_arch(), regs->regs[3],
+ regs->regs[4], regs->regs[5],
+ regs->regs[6], regs->regs[7]);
return ret ?: regs->regs[0];
}
@@ -529,7 +530,9 @@ asmlinkage void do_syscall_trace_leave(struct pt_regs *regs)
{
int step;
- audit_syscall_exit(regs);
+ if (unlikely(current->audit_context))
+ audit_syscall_exit(AUDITSC_RESULT(regs->regs[0]),
+ regs->regs[0]);
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_exit(regs, regs->regs[0]);
diff --git a/trunk/arch/sh/kernel/ptrace_64.c b/trunk/arch/sh/kernel/ptrace_64.c
index 3d0080b5c976..c8f97649f354 100644
--- a/trunk/arch/sh/kernel/ptrace_64.c
+++ b/trunk/arch/sh/kernel/ptrace_64.c
@@ -536,9 +536,10 @@ asmlinkage long long do_syscall_trace_enter(struct pt_regs *regs)
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_enter(regs, regs->regs[9]);
- audit_syscall_entry(audit_arch(), regs->regs[1],
- regs->regs[2], regs->regs[3],
- regs->regs[4], regs->regs[5]);
+ if (unlikely(current->audit_context))
+ audit_syscall_entry(audit_arch(), regs->regs[1],
+ regs->regs[2], regs->regs[3],
+ regs->regs[4], regs->regs[5]);
return ret ?: regs->regs[9];
}
@@ -547,7 +548,9 @@ asmlinkage void do_syscall_trace_leave(struct pt_regs *regs)
{
int step;
- audit_syscall_exit(regs);
+ if (unlikely(current->audit_context))
+ audit_syscall_exit(AUDITSC_RESULT(regs->regs[9]),
+ regs->regs[9]);
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_exit(regs, regs->regs[9]);
diff --git a/trunk/arch/sparc/include/asm/ptrace.h b/trunk/arch/sparc/include/asm/ptrace.h
index c00c3b5c2806..a0e1bcf843a1 100644
--- a/trunk/arch/sparc/include/asm/ptrace.h
+++ b/trunk/arch/sparc/include/asm/ptrace.h
@@ -207,15 +207,7 @@ do { current_thread_info()->syscall_noerror = 1; \
#define instruction_pointer(regs) ((regs)->tpc)
#define instruction_pointer_set(regs, val) ((regs)->tpc = (val))
#define user_stack_pointer(regs) ((regs)->u_regs[UREG_FP])
-static inline int is_syscall_success(struct pt_regs *regs)
-{
- return !(regs->tstate & (TSTATE_XCARRY | TSTATE_ICARRY));
-}
-
-static inline long regs_return_value(struct pt_regs *regs)
-{
- return regs->u_regs[UREG_I0];
-}
+#define regs_return_value(regs) ((regs)->u_regs[UREG_I0])
#ifdef CONFIG_SMP
extern unsigned long profile_pc(struct pt_regs *);
#else
diff --git a/trunk/arch/sparc/kernel/ptrace_64.c b/trunk/arch/sparc/kernel/ptrace_64.c
index 9388844cd88c..96ee50a80661 100644
--- a/trunk/arch/sparc/kernel/ptrace_64.c
+++ b/trunk/arch/sparc/kernel/ptrace_64.c
@@ -1071,22 +1071,32 @@ asmlinkage int syscall_trace_enter(struct pt_regs *regs)
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_enter(regs, regs->u_regs[UREG_G1]);
- audit_syscall_entry((test_thread_flag(TIF_32BIT) ?
- AUDIT_ARCH_SPARC :
- AUDIT_ARCH_SPARC64),
- regs->u_regs[UREG_G1],
- regs->u_regs[UREG_I0],
- regs->u_regs[UREG_I1],
- regs->u_regs[UREG_I2],
- regs->u_regs[UREG_I3]);
+ if (unlikely(current->audit_context) && !ret)
+ audit_syscall_entry((test_thread_flag(TIF_32BIT) ?
+ AUDIT_ARCH_SPARC :
+ AUDIT_ARCH_SPARC64),
+ regs->u_regs[UREG_G1],
+ regs->u_regs[UREG_I0],
+ regs->u_regs[UREG_I1],
+ regs->u_regs[UREG_I2],
+ regs->u_regs[UREG_I3]);
return ret;
}
asmlinkage void syscall_trace_leave(struct pt_regs *regs)
{
- audit_syscall_exit(regs);
+#ifdef CONFIG_AUDITSYSCALL
+ if (unlikely(current->audit_context)) {
+ unsigned long tstate = regs->tstate;
+ int result = AUDITSC_SUCCESS;
+ if (unlikely(tstate & (TSTATE_XCARRY | TSTATE_ICARRY)))
+ result = AUDITSC_FAILURE;
+
+ audit_syscall_exit(result, regs->u_regs[UREG_I0]);
+ }
+#endif
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_exit(regs, regs->u_regs[UREG_G1]);
diff --git a/trunk/arch/um/Makefile b/trunk/arch/um/Makefile
index 28688e6d96d7..7730af6ec13f 100644
--- a/trunk/arch/um/Makefile
+++ b/trunk/arch/um/Makefile
@@ -64,8 +64,7 @@ USER_CFLAGS = $(patsubst $(KERNEL_DEFINES),,$(patsubst -D__KERNEL__,,\
#This will adjust *FLAGS accordingly to the platform.
include $(srctree)/$(ARCH_DIR)/Makefile-os-$(OS)
-KBUILD_CPPFLAGS += -I$(srctree)/$(HOST_DIR)/include \
- -I$(HOST_DIR)/include/generated
+KBUILD_CPPFLAGS += -I$(srctree)/$(HOST_DIR)/include
# -Derrno=kernel_errno - This turns all kernel references to errno into
# kernel_errno to separate them from the libc errno. This allows -fno-common
@@ -97,10 +96,6 @@ endef
KBUILD_KCONFIG := $(HOST_DIR)/um/Kconfig
-archheaders:
- $(Q)$(MAKE) -C '$(srctree)' KBUILD_SRC= \
- ARCH=$(SUBARCH) O='$(objtree)' archheaders
-
archprepare: include/generated/user_constants.h
LINK-$(CONFIG_LD_SCRIPT_STATIC) += -static
@@ -140,7 +135,7 @@ archclean:
# Generated files
-$(HOST_DIR)/um/user-offsets.s: __headers FORCE
+$(HOST_DIR)/um/user-offsets.s: FORCE
$(Q)$(MAKE) $(build)=$(HOST_DIR)/um $@
define filechk_gen-asm-offsets
diff --git a/trunk/arch/um/kernel/ptrace.c b/trunk/arch/um/kernel/ptrace.c
index 06b190390505..c9da32b0c707 100644
--- a/trunk/arch/um/kernel/ptrace.c
+++ b/trunk/arch/um/kernel/ptrace.c
@@ -167,15 +167,17 @@ void syscall_trace(struct uml_pt_regs *regs, int entryexit)
int is_singlestep = (current->ptrace & PT_DTRACE) && entryexit;
int tracesysgood;
- if (!entryexit)
- audit_syscall_entry(HOST_AUDIT_ARCH,
- UPT_SYSCALL_NR(regs),
- UPT_SYSCALL_ARG1(regs),
- UPT_SYSCALL_ARG2(regs),
- UPT_SYSCALL_ARG3(regs),
- UPT_SYSCALL_ARG4(regs));
- else
- audit_syscall_exit(regs);
+ if (unlikely(current->audit_context)) {
+ if (!entryexit)
+ audit_syscall_entry(HOST_AUDIT_ARCH,
+ UPT_SYSCALL_NR(regs),
+ UPT_SYSCALL_ARG1(regs),
+ UPT_SYSCALL_ARG2(regs),
+ UPT_SYSCALL_ARG3(regs),
+ UPT_SYSCALL_ARG4(regs));
+ else audit_syscall_exit(AUDITSC_RESULT(UPT_SYSCALL_RET(regs)),
+ UPT_SYSCALL_RET(regs));
+ }
/* Fake a debug trap */
if (is_singlestep)
diff --git a/trunk/arch/x86/Makefile b/trunk/arch/x86/Makefile
index 209ba1294592..b02e509072a7 100644
--- a/trunk/arch/x86/Makefile
+++ b/trunk/arch/x86/Makefile
@@ -117,12 +117,6 @@ KBUILD_CFLAGS += $(call cc-option,-mno-sse -mno-mmx -mno-sse2 -mno-3dnow,)
KBUILD_CFLAGS += $(mflags-y)
KBUILD_AFLAGS += $(mflags-y)
-###
-# Syscall table generation
-
-archheaders:
- $(Q)$(MAKE) $(build)=arch/x86/syscalls all
-
###
# Kernel objects
diff --git a/trunk/arch/x86/ia32/Makefile b/trunk/arch/x86/ia32/Makefile
index 455646e0e532..52d0ccfcf6ea 100644
--- a/trunk/arch/x86/ia32/Makefile
+++ b/trunk/arch/x86/ia32/Makefile
@@ -3,7 +3,6 @@
#
obj-$(CONFIG_IA32_EMULATION) := ia32entry.o sys_ia32.o ia32_signal.o
-obj-$(CONFIG_IA32_EMULATION) += nosyscall.o syscall_ia32.o
sysv-$(CONFIG_SYSVIPC) := ipc32.o
obj-$(CONFIG_IA32_EMULATION) += $(sysv-y)
diff --git a/trunk/arch/x86/ia32/ia32entry.S b/trunk/arch/x86/ia32/ia32entry.S
index e3e734005e19..3e274564f6bf 100644
--- a/trunk/arch/x86/ia32/ia32entry.S
+++ b/trunk/arch/x86/ia32/ia32entry.S
@@ -14,7 +14,6 @@
#include
#include
#include
-#include
/* Avoid __ASSEMBLER__'ifying just for this. */
#include
@@ -28,6 +27,8 @@
.section .entry.text, "ax"
+#define IA32_NR_syscalls ((ia32_syscall_end - ia32_sys_call_table)/8)
+
.macro IA32_ARG_FIXUP noebp=0
movl %edi,%r8d
.if \noebp
@@ -190,7 +191,7 @@ sysexit_from_sys_call:
movl %ebx,%edx /* 3rd arg: 1st syscall arg */
movl %eax,%esi /* 2nd arg: syscall number */
movl $AUDIT_ARCH_I386,%edi /* 1st arg: audit arch */
- call __audit_syscall_entry
+ call audit_syscall_entry
movl RAX-ARGOFFSET(%rsp),%eax /* reload syscall number */
cmpq $(IA32_NR_syscalls-1),%rax
ja ia32_badsys
@@ -207,13 +208,12 @@ sysexit_from_sys_call:
TRACE_IRQS_ON
sti
movl %eax,%esi /* second arg, syscall return value */
- cmpl $-MAX_ERRNO,%eax /* is it an error ? */
- jbe 1f
- movslq %eax, %rsi /* if error sign extend to 64 bits */
-1: setbe %al /* 1 if error, 0 if not */
+ cmpl $0,%eax /* is it < 0? */
+ setl %al /* 1 if so, 0 if not */
movzbl %al,%edi /* zero-extend that into %edi */
- call __audit_syscall_exit
- movq RAX-ARGOFFSET(%rsp),%rax /* reload syscall return value */
+ inc %edi /* first arg, 0->1(AUDITSC_SUCCESS), 1->2(AUDITSC_FAILURE) */
+ call audit_syscall_exit
+ movl RAX-ARGOFFSET(%rsp),%eax /* reload syscall return value */
movl $(_TIF_ALLWORK_MASK & ~_TIF_SYSCALL_AUDIT),%edi
cli
TRACE_IRQS_OFF
@@ -447,6 +447,9 @@ ia32_badsys:
movq $-ENOSYS,%rax
jmp ia32_sysret
+quiet_ni_syscall:
+ movq $-ENOSYS,%rax
+ ret
CFI_ENDPROC
.macro PTREGSCALL label, func, arg
@@ -491,3 +494,357 @@ ia32_ptregs_common:
jmp ia32_sysret /* misbalances the return cache */
CFI_ENDPROC
END(ia32_ptregs_common)
+
+ .section .rodata,"a"
+ .align 8
+ia32_sys_call_table:
+ .quad sys_restart_syscall
+ .quad sys_exit
+ .quad stub32_fork
+ .quad sys_read
+ .quad sys_write
+ .quad compat_sys_open /* 5 */
+ .quad sys_close
+ .quad sys32_waitpid
+ .quad sys_creat
+ .quad sys_link
+ .quad sys_unlink /* 10 */
+ .quad stub32_execve
+ .quad sys_chdir
+ .quad compat_sys_time
+ .quad sys_mknod
+ .quad sys_chmod /* 15 */
+ .quad sys_lchown16
+ .quad quiet_ni_syscall /* old break syscall holder */
+ .quad sys_stat
+ .quad sys32_lseek
+ .quad sys_getpid /* 20 */
+ .quad compat_sys_mount /* mount */
+ .quad sys_oldumount /* old_umount */
+ .quad sys_setuid16
+ .quad sys_getuid16
+ .quad compat_sys_stime /* stime */ /* 25 */
+ .quad compat_sys_ptrace /* ptrace */
+ .quad sys_alarm
+ .quad sys_fstat /* (old)fstat */
+ .quad sys_pause
+ .quad compat_sys_utime /* 30 */
+ .quad quiet_ni_syscall /* old stty syscall holder */
+ .quad quiet_ni_syscall /* old gtty syscall holder */
+ .quad sys_access
+ .quad sys_nice
+ .quad quiet_ni_syscall /* 35 */ /* old ftime syscall holder */
+ .quad sys_sync
+ .quad sys32_kill
+ .quad sys_rename
+ .quad sys_mkdir
+ .quad sys_rmdir /* 40 */
+ .quad sys_dup
+ .quad sys_pipe
+ .quad compat_sys_times
+ .quad quiet_ni_syscall /* old prof syscall holder */
+ .quad sys_brk /* 45 */
+ .quad sys_setgid16
+ .quad sys_getgid16
+ .quad sys_signal
+ .quad sys_geteuid16
+ .quad sys_getegid16 /* 50 */
+ .quad sys_acct
+ .quad sys_umount /* new_umount */
+ .quad quiet_ni_syscall /* old lock syscall holder */
+ .quad compat_sys_ioctl
+ .quad compat_sys_fcntl64 /* 55 */
+ .quad quiet_ni_syscall /* old mpx syscall holder */
+ .quad sys_setpgid
+ .quad quiet_ni_syscall /* old ulimit syscall holder */
+ .quad sys_olduname
+ .quad sys_umask /* 60 */
+ .quad sys_chroot
+ .quad compat_sys_ustat
+ .quad sys_dup2
+ .quad sys_getppid
+ .quad sys_getpgrp /* 65 */
+ .quad sys_setsid
+ .quad sys32_sigaction
+ .quad sys_sgetmask
+ .quad sys_ssetmask
+ .quad sys_setreuid16 /* 70 */
+ .quad sys_setregid16
+ .quad sys32_sigsuspend
+ .quad compat_sys_sigpending
+ .quad sys_sethostname
+ .quad compat_sys_setrlimit /* 75 */
+ .quad compat_sys_old_getrlimit /* old_getrlimit */
+ .quad compat_sys_getrusage
+ .quad compat_sys_gettimeofday
+ .quad compat_sys_settimeofday
+ .quad sys_getgroups16 /* 80 */
+ .quad sys_setgroups16
+ .quad compat_sys_old_select
+ .quad sys_symlink
+ .quad sys_lstat
+ .quad sys_readlink /* 85 */
+ .quad sys_uselib
+ .quad sys_swapon
+ .quad sys_reboot
+ .quad compat_sys_old_readdir
+ .quad sys32_mmap /* 90 */
+ .quad sys_munmap
+ .quad sys_truncate
+ .quad sys_ftruncate
+ .quad sys_fchmod
+ .quad sys_fchown16 /* 95 */
+ .quad sys_getpriority
+ .quad sys_setpriority
+ .quad quiet_ni_syscall /* old profil syscall holder */
+ .quad compat_sys_statfs
+ .quad compat_sys_fstatfs /* 100 */
+ .quad sys_ioperm
+ .quad compat_sys_socketcall
+ .quad sys_syslog
+ .quad compat_sys_setitimer
+ .quad compat_sys_getitimer /* 105 */
+ .quad compat_sys_newstat
+ .quad compat_sys_newlstat
+ .quad compat_sys_newfstat
+ .quad sys_uname
+ .quad stub32_iopl /* 110 */
+ .quad sys_vhangup
+ .quad quiet_ni_syscall /* old "idle" system call */
+ .quad sys32_vm86_warning /* vm86old */
+ .quad compat_sys_wait4
+ .quad sys_swapoff /* 115 */
+ .quad compat_sys_sysinfo
+ .quad sys32_ipc
+ .quad sys_fsync
+ .quad stub32_sigreturn
+ .quad stub32_clone /* 120 */
+ .quad sys_setdomainname
+ .quad sys_newuname
+ .quad sys_modify_ldt
+ .quad compat_sys_adjtimex
+ .quad sys32_mprotect /* 125 */
+ .quad compat_sys_sigprocmask
+ .quad quiet_ni_syscall /* create_module */
+ .quad sys_init_module
+ .quad sys_delete_module
+ .quad quiet_ni_syscall /* 130 get_kernel_syms */
+ .quad sys32_quotactl
+ .quad sys_getpgid
+ .quad sys_fchdir
+ .quad quiet_ni_syscall /* bdflush */
+ .quad sys_sysfs /* 135 */
+ .quad sys_personality
+ .quad quiet_ni_syscall /* for afs_syscall */
+ .quad sys_setfsuid16
+ .quad sys_setfsgid16
+ .quad sys_llseek /* 140 */
+ .quad compat_sys_getdents
+ .quad compat_sys_select
+ .quad sys_flock
+ .quad sys_msync
+ .quad compat_sys_readv /* 145 */
+ .quad compat_sys_writev
+ .quad sys_getsid
+ .quad sys_fdatasync
+ .quad compat_sys_sysctl /* sysctl */
+ .quad sys_mlock /* 150 */
+ .quad sys_munlock
+ .quad sys_mlockall
+ .quad sys_munlockall
+ .quad sys_sched_setparam
+ .quad sys_sched_getparam /* 155 */
+ .quad sys_sched_setscheduler
+ .quad sys_sched_getscheduler
+ .quad sys_sched_yield
+ .quad sys_sched_get_priority_max
+ .quad sys_sched_get_priority_min /* 160 */
+ .quad sys32_sched_rr_get_interval
+ .quad compat_sys_nanosleep
+ .quad sys_mremap
+ .quad sys_setresuid16
+ .quad sys_getresuid16 /* 165 */
+ .quad sys32_vm86_warning /* vm86 */
+ .quad quiet_ni_syscall /* query_module */
+ .quad sys_poll
+ .quad quiet_ni_syscall /* old nfsservctl */
+ .quad sys_setresgid16 /* 170 */
+ .quad sys_getresgid16
+ .quad sys_prctl
+ .quad stub32_rt_sigreturn
+ .quad sys32_rt_sigaction
+ .quad sys32_rt_sigprocmask /* 175 */
+ .quad sys32_rt_sigpending
+ .quad compat_sys_rt_sigtimedwait
+ .quad sys32_rt_sigqueueinfo
+ .quad sys_rt_sigsuspend
+ .quad sys32_pread /* 180 */
+ .quad sys32_pwrite
+ .quad sys_chown16
+ .quad sys_getcwd
+ .quad sys_capget
+ .quad sys_capset
+ .quad stub32_sigaltstack
+ .quad sys32_sendfile
+ .quad quiet_ni_syscall /* streams1 */
+ .quad quiet_ni_syscall /* streams2 */
+ .quad stub32_vfork /* 190 */
+ .quad compat_sys_getrlimit
+ .quad sys_mmap_pgoff
+ .quad sys32_truncate64
+ .quad sys32_ftruncate64
+ .quad sys32_stat64 /* 195 */
+ .quad sys32_lstat64
+ .quad sys32_fstat64
+ .quad sys_lchown
+ .quad sys_getuid
+ .quad sys_getgid /* 200 */
+ .quad sys_geteuid
+ .quad sys_getegid
+ .quad sys_setreuid
+ .quad sys_setregid
+ .quad sys_getgroups /* 205 */
+ .quad sys_setgroups
+ .quad sys_fchown
+ .quad sys_setresuid
+ .quad sys_getresuid
+ .quad sys_setresgid /* 210 */
+ .quad sys_getresgid
+ .quad sys_chown
+ .quad sys_setuid
+ .quad sys_setgid
+ .quad sys_setfsuid /* 215 */
+ .quad sys_setfsgid
+ .quad sys_pivot_root
+ .quad sys_mincore
+ .quad sys_madvise
+ .quad compat_sys_getdents64 /* 220 getdents64 */
+ .quad compat_sys_fcntl64
+ .quad quiet_ni_syscall /* tux */
+ .quad quiet_ni_syscall /* security */
+ .quad sys_gettid
+ .quad sys32_readahead /* 225 */
+ .quad sys_setxattr
+ .quad sys_lsetxattr
+ .quad sys_fsetxattr
+ .quad sys_getxattr
+ .quad sys_lgetxattr /* 230 */
+ .quad sys_fgetxattr
+ .quad sys_listxattr
+ .quad sys_llistxattr
+ .quad sys_flistxattr
+ .quad sys_removexattr /* 235 */
+ .quad sys_lremovexattr
+ .quad sys_fremovexattr
+ .quad sys_tkill
+ .quad sys_sendfile64
+ .quad compat_sys_futex /* 240 */
+ .quad compat_sys_sched_setaffinity
+ .quad compat_sys_sched_getaffinity
+ .quad sys_set_thread_area
+ .quad sys_get_thread_area
+ .quad compat_sys_io_setup /* 245 */
+ .quad sys_io_destroy
+ .quad compat_sys_io_getevents
+ .quad compat_sys_io_submit
+ .quad sys_io_cancel
+ .quad sys32_fadvise64 /* 250 */
+ .quad quiet_ni_syscall /* free_huge_pages */
+ .quad sys_exit_group
+ .quad sys32_lookup_dcookie
+ .quad sys_epoll_create
+ .quad sys_epoll_ctl /* 255 */
+ .quad sys_epoll_wait
+ .quad sys_remap_file_pages
+ .quad sys_set_tid_address
+ .quad compat_sys_timer_create
+ .quad compat_sys_timer_settime /* 260 */
+ .quad compat_sys_timer_gettime
+ .quad sys_timer_getoverrun
+ .quad sys_timer_delete
+ .quad compat_sys_clock_settime
+ .quad compat_sys_clock_gettime /* 265 */
+ .quad compat_sys_clock_getres
+ .quad compat_sys_clock_nanosleep
+ .quad compat_sys_statfs64
+ .quad compat_sys_fstatfs64
+ .quad sys_tgkill /* 270 */
+ .quad compat_sys_utimes
+ .quad sys32_fadvise64_64
+ .quad quiet_ni_syscall /* sys_vserver */
+ .quad sys_mbind
+ .quad compat_sys_get_mempolicy /* 275 */
+ .quad sys_set_mempolicy
+ .quad compat_sys_mq_open
+ .quad sys_mq_unlink
+ .quad compat_sys_mq_timedsend
+ .quad compat_sys_mq_timedreceive /* 280 */
+ .quad compat_sys_mq_notify
+ .quad compat_sys_mq_getsetattr
+ .quad compat_sys_kexec_load /* reserved for kexec */
+ .quad compat_sys_waitid
+ .quad quiet_ni_syscall /* 285: sys_altroot */
+ .quad sys_add_key
+ .quad sys_request_key
+ .quad sys_keyctl
+ .quad sys_ioprio_set
+ .quad sys_ioprio_get /* 290 */
+ .quad sys_inotify_init
+ .quad sys_inotify_add_watch
+ .quad sys_inotify_rm_watch
+ .quad sys_migrate_pages
+ .quad compat_sys_openat /* 295 */
+ .quad sys_mkdirat
+ .quad sys_mknodat
+ .quad sys_fchownat
+ .quad compat_sys_futimesat
+ .quad sys32_fstatat /* 300 */
+ .quad sys_unlinkat
+ .quad sys_renameat
+ .quad sys_linkat
+ .quad sys_symlinkat
+ .quad sys_readlinkat /* 305 */
+ .quad sys_fchmodat
+ .quad sys_faccessat
+ .quad compat_sys_pselect6
+ .quad compat_sys_ppoll
+ .quad sys_unshare /* 310 */
+ .quad compat_sys_set_robust_list
+ .quad compat_sys_get_robust_list
+ .quad sys_splice
+ .quad sys32_sync_file_range
+ .quad sys_tee /* 315 */
+ .quad compat_sys_vmsplice
+ .quad compat_sys_move_pages
+ .quad sys_getcpu
+ .quad sys_epoll_pwait
+ .quad compat_sys_utimensat /* 320 */
+ .quad compat_sys_signalfd
+ .quad sys_timerfd_create
+ .quad sys_eventfd
+ .quad sys32_fallocate
+ .quad compat_sys_timerfd_settime /* 325 */
+ .quad compat_sys_timerfd_gettime
+ .quad compat_sys_signalfd4
+ .quad sys_eventfd2
+ .quad sys_epoll_create1
+ .quad sys_dup3 /* 330 */
+ .quad sys_pipe2
+ .quad sys_inotify_init1
+ .quad compat_sys_preadv
+ .quad compat_sys_pwritev
+ .quad compat_sys_rt_tgsigqueueinfo /* 335 */
+ .quad sys_perf_event_open
+ .quad compat_sys_recvmmsg
+ .quad sys_fanotify_init
+ .quad sys32_fanotify_mark
+ .quad sys_prlimit64 /* 340 */
+ .quad sys_name_to_handle_at
+ .quad compat_sys_open_by_handle_at
+ .quad compat_sys_clock_adjtime
+ .quad sys_syncfs
+ .quad compat_sys_sendmmsg /* 345 */
+ .quad sys_setns
+ .quad compat_sys_process_vm_readv
+ .quad compat_sys_process_vm_writev
+ia32_syscall_end:
diff --git a/trunk/arch/x86/ia32/nosyscall.c b/trunk/arch/x86/ia32/nosyscall.c
deleted file mode 100644
index 51ecd5b4e787..000000000000
--- a/trunk/arch/x86/ia32/nosyscall.c
+++ /dev/null
@@ -1,7 +0,0 @@
-#include
-#include
-
-long compat_ni_syscall(void)
-{
- return -ENOSYS;
-}
diff --git a/trunk/arch/x86/ia32/syscall_ia32.c b/trunk/arch/x86/ia32/syscall_ia32.c
deleted file mode 100644
index 4754ba0f5d9f..000000000000
--- a/trunk/arch/x86/ia32/syscall_ia32.c
+++ /dev/null
@@ -1,25 +0,0 @@
-/* System call table for ia32 emulation. */
-
-#include
-#include
-#include
-#include
-
-#define __SYSCALL_I386(nr, sym, compat) extern asmlinkage void compat(void) ;
-#include
-#undef __SYSCALL_I386
-
-#define __SYSCALL_I386(nr, sym, compat) [nr] = compat,
-
-typedef void (*sys_call_ptr_t)(void);
-
-extern void compat_ni_syscall(void);
-
-const sys_call_ptr_t ia32_sys_call_table[__NR_ia32_syscall_max+1] = {
- /*
- * Smells like a compiler bug -- it doesn't work
- * when the & below is removed.
- */
- [0 ... __NR_ia32_syscall_max] = &compat_ni_syscall,
-#include
-};
diff --git a/trunk/arch/x86/include/asm/Kbuild b/trunk/arch/x86/include/asm/Kbuild
index b57e6a43a37a..6fa90a845e4c 100644
--- a/trunk/arch/x86/include/asm/Kbuild
+++ b/trunk/arch/x86/include/asm/Kbuild
@@ -19,8 +19,7 @@ header-y += processor-flags.h
header-y += ptrace-abi.h
header-y += sigcontext32.h
header-y += ucontext.h
+header-y += unistd_32.h
+header-y += unistd_64.h
header-y += vm86.h
header-y += vsyscall.h
-
-genhdr-y += unistd_32.h
-genhdr-y += unistd_64.h
diff --git a/trunk/arch/x86/include/asm/ia32_unistd.h b/trunk/arch/x86/include/asm/ia32_unistd.h
index b0d5716ca1e4..976f6ecd2ce6 100644
--- a/trunk/arch/x86/include/asm/ia32_unistd.h
+++ b/trunk/arch/x86/include/asm/ia32_unistd.h
@@ -2,10 +2,17 @@
#define _ASM_X86_IA32_UNISTD_H
/*
- * This file contains the system call numbers of the ia32 compat ABI,
+ * This file contains the system call numbers of the ia32 port,
* this is for the kernel only.
+ * Only add syscalls here where some part of the kernel needs to know
+ * the number. This should be otherwise in sync with asm-x86/unistd_32.h. -AK
*/
-#define __SYSCALL_ia32_NR(x) (x)
-#include
+
+#define __NR_ia32_restart_syscall 0
+#define __NR_ia32_exit 1
+#define __NR_ia32_read 3
+#define __NR_ia32_write 4
+#define __NR_ia32_sigreturn 119
+#define __NR_ia32_rt_sigreturn 173
#endif /* _ASM_X86_IA32_UNISTD_H */
diff --git a/trunk/arch/x86/include/asm/mce.h b/trunk/arch/x86/include/asm/mce.h
index 6aefb14cbbc5..f35ce43c1a77 100644
--- a/trunk/arch/x86/include/asm/mce.h
+++ b/trunk/arch/x86/include/asm/mce.h
@@ -151,7 +151,7 @@ static inline void enable_p5_mce(void) {}
void mce_setup(struct mce *m);
void mce_log(struct mce *m);
-extern struct device *mce_device[CONFIG_NR_CPUS];
+DECLARE_PER_CPU(struct device, mce_device);
/*
* Maximum banks number.
diff --git a/trunk/arch/x86/include/asm/syscall.h b/trunk/arch/x86/include/asm/syscall.h
index d962e5652a73..c4a348f7bd43 100644
--- a/trunk/arch/x86/include/asm/syscall.h
+++ b/trunk/arch/x86/include/asm/syscall.h
@@ -15,7 +15,6 @@
#include
#include
-#include /* For NR_syscalls */
extern const unsigned long sys_call_table[];
diff --git a/trunk/arch/x86/include/asm/unistd.h b/trunk/arch/x86/include/asm/unistd.h
index b4a3db7ce140..2a58ed3e51d8 100644
--- a/trunk/arch/x86/include/asm/unistd.h
+++ b/trunk/arch/x86/include/asm/unistd.h
@@ -1,59 +1,13 @@
-#ifndef _ASM_X86_UNISTD_H
-#define _ASM_X86_UNISTD_H 1
-
#ifdef __KERNEL__
# ifdef CONFIG_X86_32
-
-# include
-# define __ARCH_WANT_IPC_PARSE_VERSION
-# define __ARCH_WANT_STAT64
-# define __ARCH_WANT_SYS_OLD_MMAP
-# define __ARCH_WANT_SYS_OLD_SELECT
-
+# include "unistd_32.h"
# else
-
-# include
-# define __ARCH_WANT_COMPAT_SYS_TIME
-
+# include "unistd_64.h"
# endif
-
-# define __ARCH_WANT_OLD_READDIR
-# define __ARCH_WANT_OLD_STAT
-# define __ARCH_WANT_SYS_ALARM
-# define __ARCH_WANT_SYS_FADVISE64
-# define __ARCH_WANT_SYS_GETHOSTNAME
-# define __ARCH_WANT_SYS_GETPGRP
-# define __ARCH_WANT_SYS_LLSEEK
-# define __ARCH_WANT_SYS_NICE
-# define __ARCH_WANT_SYS_OLDUMOUNT
-# define __ARCH_WANT_SYS_OLD_GETRLIMIT
-# define __ARCH_WANT_SYS_OLD_UNAME
-# define __ARCH_WANT_SYS_PAUSE
-# define __ARCH_WANT_SYS_RT_SIGACTION
-# define __ARCH_WANT_SYS_RT_SIGSUSPEND
-# define __ARCH_WANT_SYS_SGETMASK
-# define __ARCH_WANT_SYS_SIGNAL
-# define __ARCH_WANT_SYS_SIGPENDING
-# define __ARCH_WANT_SYS_SIGPROCMASK
-# define __ARCH_WANT_SYS_SOCKETCALL
-# define __ARCH_WANT_SYS_TIME
-# define __ARCH_WANT_SYS_UTIME
-# define __ARCH_WANT_SYS_WAITPID
-
-/*
- * "Conditional" syscalls
- *
- * What we want is __attribute__((weak,alias("sys_ni_syscall"))),
- * but it doesn't work on all toolchains, so we just do it by hand
- */
-# define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall")
-
#else
# ifdef __i386__
-# include
+# include "unistd_32.h"
# else
-# include
+# include "unistd_64.h"
# endif
#endif
-
-#endif /* _ASM_X86_UNISTD_H */
diff --git a/trunk/arch/x86/include/asm/unistd_32.h b/trunk/arch/x86/include/asm/unistd_32.h
new file mode 100644
index 000000000000..599c77d38f33
--- /dev/null
+++ b/trunk/arch/x86/include/asm/unistd_32.h
@@ -0,0 +1,401 @@
+#ifndef _ASM_X86_UNISTD_32_H
+#define _ASM_X86_UNISTD_32_H
+
+/*
+ * This file contains the system call numbers.
+ */
+
+#define __NR_restart_syscall 0
+#define __NR_exit 1
+#define __NR_fork 2
+#define __NR_read 3
+#define __NR_write 4
+#define __NR_open 5
+#define __NR_close 6
+#define __NR_waitpid 7
+#define __NR_creat 8
+#define __NR_link 9
+#define __NR_unlink 10
+#define __NR_execve 11
+#define __NR_chdir 12
+#define __NR_time 13
+#define __NR_mknod 14
+#define __NR_chmod 15
+#define __NR_lchown 16
+#define __NR_break 17
+#define __NR_oldstat 18
+#define __NR_lseek 19
+#define __NR_getpid 20
+#define __NR_mount 21
+#define __NR_umount 22
+#define __NR_setuid 23
+#define __NR_getuid 24
+#define __NR_stime 25
+#define __NR_ptrace 26
+#define __NR_alarm 27
+#define __NR_oldfstat 28
+#define __NR_pause 29
+#define __NR_utime 30
+#define __NR_stty 31
+#define __NR_gtty 32
+#define __NR_access 33
+#define __NR_nice 34
+#define __NR_ftime 35
+#define __NR_sync 36
+#define __NR_kill 37
+#define __NR_rename 38
+#define __NR_mkdir 39
+#define __NR_rmdir 40
+#define __NR_dup 41
+#define __NR_pipe 42
+#define __NR_times 43
+#define __NR_prof 44
+#define __NR_brk 45
+#define __NR_setgid 46
+#define __NR_getgid 47
+#define __NR_signal 48
+#define __NR_geteuid 49
+#define __NR_getegid 50
+#define __NR_acct 51
+#define __NR_umount2 52
+#define __NR_lock 53
+#define __NR_ioctl 54
+#define __NR_fcntl 55
+#define __NR_mpx 56
+#define __NR_setpgid 57
+#define __NR_ulimit 58
+#define __NR_oldolduname 59
+#define __NR_umask 60
+#define __NR_chroot 61
+#define __NR_ustat 62
+#define __NR_dup2 63
+#define __NR_getppid 64
+#define __NR_getpgrp 65
+#define __NR_setsid 66
+#define __NR_sigaction 67
+#define __NR_sgetmask 68
+#define __NR_ssetmask 69
+#define __NR_setreuid 70
+#define __NR_setregid 71
+#define __NR_sigsuspend 72
+#define __NR_sigpending 73
+#define __NR_sethostname 74
+#define __NR_setrlimit 75
+#define __NR_getrlimit 76 /* Back compatible 2Gig limited rlimit */
+#define __NR_getrusage 77
+#define __NR_gettimeofday 78
+#define __NR_settimeofday 79
+#define __NR_getgroups 80
+#define __NR_setgroups 81
+#define __NR_select 82
+#define __NR_symlink 83
+#define __NR_oldlstat 84
+#define __NR_readlink 85
+#define __NR_uselib 86
+#define __NR_swapon 87
+#define __NR_reboot 88
+#define __NR_readdir 89
+#define __NR_mmap 90
+#define __NR_munmap 91
+#define __NR_truncate 92
+#define __NR_ftruncate 93
+#define __NR_fchmod 94
+#define __NR_fchown 95
+#define __NR_getpriority 96
+#define __NR_setpriority 97
+#define __NR_profil 98
+#define __NR_statfs 99
+#define __NR_fstatfs 100
+#define __NR_ioperm 101
+#define __NR_socketcall 102
+#define __NR_syslog 103
+#define __NR_setitimer 104
+#define __NR_getitimer 105
+#define __NR_stat 106
+#define __NR_lstat 107
+#define __NR_fstat 108
+#define __NR_olduname 109
+#define __NR_iopl 110
+#define __NR_vhangup 111
+#define __NR_idle 112
+#define __NR_vm86old 113
+#define __NR_wait4 114
+#define __NR_swapoff 115
+#define __NR_sysinfo 116
+#define __NR_ipc 117
+#define __NR_fsync 118
+#define __NR_sigreturn 119
+#define __NR_clone 120
+#define __NR_setdomainname 121
+#define __NR_uname 122
+#define __NR_modify_ldt 123
+#define __NR_adjtimex 124
+#define __NR_mprotect 125
+#define __NR_sigprocmask 126
+#define __NR_create_module 127
+#define __NR_init_module 128
+#define __NR_delete_module 129
+#define __NR_get_kernel_syms 130
+#define __NR_quotactl 131
+#define __NR_getpgid 132
+#define __NR_fchdir 133
+#define __NR_bdflush 134
+#define __NR_sysfs 135
+#define __NR_personality 136
+#define __NR_afs_syscall 137 /* Syscall for Andrew File System */
+#define __NR_setfsuid 138
+#define __NR_setfsgid 139
+#define __NR__llseek 140
+#define __NR_getdents 141
+#define __NR__newselect 142
+#define __NR_flock 143
+#define __NR_msync 144
+#define __NR_readv 145
+#define __NR_writev 146
+#define __NR_getsid 147
+#define __NR_fdatasync 148
+#define __NR__sysctl 149
+#define __NR_mlock 150
+#define __NR_munlock 151
+#define __NR_mlockall 152
+#define __NR_munlockall 153
+#define __NR_sched_setparam 154
+#define __NR_sched_getparam 155
+#define __NR_sched_setscheduler 156
+#define __NR_sched_getscheduler 157
+#define __NR_sched_yield 158
+#define __NR_sched_get_priority_max 159
+#define __NR_sched_get_priority_min 160
+#define __NR_sched_rr_get_interval 161
+#define __NR_nanosleep 162
+#define __NR_mremap 163
+#define __NR_setresuid 164
+#define __NR_getresuid 165
+#define __NR_vm86 166
+#define __NR_query_module 167
+#define __NR_poll 168
+#define __NR_nfsservctl 169
+#define __NR_setresgid 170
+#define __NR_getresgid 171
+#define __NR_prctl 172
+#define __NR_rt_sigreturn 173
+#define __NR_rt_sigaction 174
+#define __NR_rt_sigprocmask 175
+#define __NR_rt_sigpending 176
+#define __NR_rt_sigtimedwait 177
+#define __NR_rt_sigqueueinfo 178
+#define __NR_rt_sigsuspend 179
+#define __NR_pread64 180
+#define __NR_pwrite64 181
+#define __NR_chown 182
+#define __NR_getcwd 183
+#define __NR_capget 184
+#define __NR_capset 185
+#define __NR_sigaltstack 186
+#define __NR_sendfile 187
+#define __NR_getpmsg 188 /* some people actually want streams */
+#define __NR_putpmsg 189 /* some people actually want streams */
+#define __NR_vfork 190
+#define __NR_ugetrlimit 191 /* SuS compliant getrlimit */
+#define __NR_mmap2 192
+#define __NR_truncate64 193
+#define __NR_ftruncate64 194
+#define __NR_stat64 195
+#define __NR_lstat64 196
+#define __NR_fstat64 197
+#define __NR_lchown32 198
+#define __NR_getuid32 199
+#define __NR_getgid32 200
+#define __NR_geteuid32 201
+#define __NR_getegid32 202
+#define __NR_setreuid32 203
+#define __NR_setregid32 204
+#define __NR_getgroups32 205
+#define __NR_setgroups32 206
+#define __NR_fchown32 207
+#define __NR_setresuid32 208
+#define __NR_getresuid32 209
+#define __NR_setresgid32 210
+#define __NR_getresgid32 211
+#define __NR_chown32 212
+#define __NR_setuid32 213
+#define __NR_setgid32 214
+#define __NR_setfsuid32 215
+#define __NR_setfsgid32 216
+#define __NR_pivot_root 217
+#define __NR_mincore 218
+#define __NR_madvise 219
+#define __NR_madvise1 219 /* delete when C lib stub is removed */
+#define __NR_getdents64 220
+#define __NR_fcntl64 221
+/* 223 is unused */
+#define __NR_gettid 224
+#define __NR_readahead 225
+#define __NR_setxattr 226
+#define __NR_lsetxattr 227
+#define __NR_fsetxattr 228
+#define __NR_getxattr 229
+#define __NR_lgetxattr 230
+#define __NR_fgetxattr 231
+#define __NR_listxattr 232
+#define __NR_llistxattr 233
+#define __NR_flistxattr 234
+#define __NR_removexattr 235
+#define __NR_lremovexattr 236
+#define __NR_fremovexattr 237
+#define __NR_tkill 238
+#define __NR_sendfile64 239
+#define __NR_futex 240
+#define __NR_sched_setaffinity 241
+#define __NR_sched_getaffinity 242
+#define __NR_set_thread_area 243
+#define __NR_get_thread_area 244
+#define __NR_io_setup 245
+#define __NR_io_destroy 246
+#define __NR_io_getevents 247
+#define __NR_io_submit 248
+#define __NR_io_cancel 249
+#define __NR_fadvise64 250
+/* 251 is available for reuse (was briefly sys_set_zone_reclaim) */
+#define __NR_exit_group 252
+#define __NR_lookup_dcookie 253
+#define __NR_epoll_create 254
+#define __NR_epoll_ctl 255
+#define __NR_epoll_wait 256
+#define __NR_remap_file_pages 257
+#define __NR_set_tid_address 258
+#define __NR_timer_create 259
+#define __NR_timer_settime (__NR_timer_create+1)
+#define __NR_timer_gettime (__NR_timer_create+2)
+#define __NR_timer_getoverrun (__NR_timer_create+3)
+#define __NR_timer_delete (__NR_timer_create+4)
+#define __NR_clock_settime (__NR_timer_create+5)
+#define __NR_clock_gettime (__NR_timer_create+6)
+#define __NR_clock_getres (__NR_timer_create+7)
+#define __NR_clock_nanosleep (__NR_timer_create+8)
+#define __NR_statfs64 268
+#define __NR_fstatfs64 269
+#define __NR_tgkill 270
+#define __NR_utimes 271
+#define __NR_fadvise64_64 272
+#define __NR_vserver 273
+#define __NR_mbind 274
+#define __NR_get_mempolicy 275
+#define __NR_set_mempolicy 276
+#define __NR_mq_open 277
+#define __NR_mq_unlink (__NR_mq_open+1)
+#define __NR_mq_timedsend (__NR_mq_open+2)
+#define __NR_mq_timedreceive (__NR_mq_open+3)
+#define __NR_mq_notify (__NR_mq_open+4)
+#define __NR_mq_getsetattr (__NR_mq_open+5)
+#define __NR_kexec_load 283
+#define __NR_waitid 284
+/* #define __NR_sys_setaltroot 285 */
+#define __NR_add_key 286
+#define __NR_request_key 287
+#define __NR_keyctl 288
+#define __NR_ioprio_set 289
+#define __NR_ioprio_get 290
+#define __NR_inotify_init 291
+#define __NR_inotify_add_watch 292
+#define __NR_inotify_rm_watch 293
+#define __NR_migrate_pages 294
+#define __NR_openat 295
+#define __NR_mkdirat 296
+#define __NR_mknodat 297
+#define __NR_fchownat 298
+#define __NR_futimesat 299
+#define __NR_fstatat64 300
+#define __NR_unlinkat 301
+#define __NR_renameat 302
+#define __NR_linkat 303
+#define __NR_symlinkat 304
+#define __NR_readlinkat 305
+#define __NR_fchmodat 306
+#define __NR_faccessat 307
+#define __NR_pselect6 308
+#define __NR_ppoll 309
+#define __NR_unshare 310
+#define __NR_set_robust_list 311
+#define __NR_get_robust_list 312
+#define __NR_splice 313
+#define __NR_sync_file_range 314
+#define __NR_tee 315
+#define __NR_vmsplice 316
+#define __NR_move_pages 317
+#define __NR_getcpu 318
+#define __NR_epoll_pwait 319
+#define __NR_utimensat 320
+#define __NR_signalfd 321
+#define __NR_timerfd_create 322
+#define __NR_eventfd 323
+#define __NR_fallocate 324
+#define __NR_timerfd_settime 325
+#define __NR_timerfd_gettime 326
+#define __NR_signalfd4 327
+#define __NR_eventfd2 328
+#define __NR_epoll_create1 329
+#define __NR_dup3 330
+#define __NR_pipe2 331
+#define __NR_inotify_init1 332
+#define __NR_preadv 333
+#define __NR_pwritev 334
+#define __NR_rt_tgsigqueueinfo 335
+#define __NR_perf_event_open 336
+#define __NR_recvmmsg 337
+#define __NR_fanotify_init 338
+#define __NR_fanotify_mark 339
+#define __NR_prlimit64 340
+#define __NR_name_to_handle_at 341
+#define __NR_open_by_handle_at 342
+#define __NR_clock_adjtime 343
+#define __NR_syncfs 344
+#define __NR_sendmmsg 345
+#define __NR_setns 346
+#define __NR_process_vm_readv 347
+#define __NR_process_vm_writev 348
+
+#ifdef __KERNEL__
+
+#define NR_syscalls 349
+
+#define __ARCH_WANT_IPC_PARSE_VERSION
+#define __ARCH_WANT_OLD_READDIR
+#define __ARCH_WANT_OLD_STAT
+#define __ARCH_WANT_STAT64
+#define __ARCH_WANT_SYS_ALARM
+#define __ARCH_WANT_SYS_GETHOSTNAME
+#define __ARCH_WANT_SYS_IPC
+#define __ARCH_WANT_SYS_PAUSE
+#define __ARCH_WANT_SYS_SGETMASK
+#define __ARCH_WANT_SYS_SIGNAL
+#define __ARCH_WANT_SYS_TIME
+#define __ARCH_WANT_SYS_UTIME
+#define __ARCH_WANT_SYS_WAITPID
+#define __ARCH_WANT_SYS_SOCKETCALL
+#define __ARCH_WANT_SYS_FADVISE64
+#define __ARCH_WANT_SYS_GETPGRP
+#define __ARCH_WANT_SYS_LLSEEK
+#define __ARCH_WANT_SYS_NICE
+#define __ARCH_WANT_SYS_OLD_GETRLIMIT
+#define __ARCH_WANT_SYS_OLD_UNAME
+#define __ARCH_WANT_SYS_OLD_MMAP
+#define __ARCH_WANT_SYS_OLD_SELECT
+#define __ARCH_WANT_SYS_OLDUMOUNT
+#define __ARCH_WANT_SYS_SIGPENDING
+#define __ARCH_WANT_SYS_SIGPROCMASK
+#define __ARCH_WANT_SYS_RT_SIGACTION
+#define __ARCH_WANT_SYS_RT_SIGSUSPEND
+
+/*
+ * "Conditional" syscalls
+ *
+ * What we want is __attribute__((weak,alias("sys_ni_syscall"))),
+ * but it doesn't work on all toolchains, so we just do it by hand
+ */
+#ifndef cond_syscall
+#define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall")
+#endif
+
+#endif /* __KERNEL__ */
+#endif /* _ASM_X86_UNISTD_32_H */
diff --git a/trunk/arch/x86/include/asm/unistd_64.h b/trunk/arch/x86/include/asm/unistd_64.h
new file mode 100644
index 000000000000..0431f193c3f2
--- /dev/null
+++ b/trunk/arch/x86/include/asm/unistd_64.h
@@ -0,0 +1,732 @@
+#ifndef _ASM_X86_UNISTD_64_H
+#define _ASM_X86_UNISTD_64_H
+
+#ifndef __SYSCALL
+#define __SYSCALL(a, b)
+#endif
+
+/*
+ * This file contains the system call numbers.
+ *
+ * Note: holes are not allowed.
+ */
+
+/* at least 8 syscall per cacheline */
+#define __NR_read 0
+__SYSCALL(__NR_read, sys_read)
+#define __NR_write 1
+__SYSCALL(__NR_write, sys_write)
+#define __NR_open 2
+__SYSCALL(__NR_open, sys_open)
+#define __NR_close 3
+__SYSCALL(__NR_close, sys_close)
+#define __NR_stat 4
+__SYSCALL(__NR_stat, sys_newstat)
+#define __NR_fstat 5
+__SYSCALL(__NR_fstat, sys_newfstat)
+#define __NR_lstat 6
+__SYSCALL(__NR_lstat, sys_newlstat)
+#define __NR_poll 7
+__SYSCALL(__NR_poll, sys_poll)
+
+#define __NR_lseek 8
+__SYSCALL(__NR_lseek, sys_lseek)
+#define __NR_mmap 9
+__SYSCALL(__NR_mmap, sys_mmap)
+#define __NR_mprotect 10
+__SYSCALL(__NR_mprotect, sys_mprotect)
+#define __NR_munmap 11
+__SYSCALL(__NR_munmap, sys_munmap)
+#define __NR_brk 12
+__SYSCALL(__NR_brk, sys_brk)
+#define __NR_rt_sigaction 13
+__SYSCALL(__NR_rt_sigaction, sys_rt_sigaction)
+#define __NR_rt_sigprocmask 14
+__SYSCALL(__NR_rt_sigprocmask, sys_rt_sigprocmask)
+#define __NR_rt_sigreturn 15
+__SYSCALL(__NR_rt_sigreturn, stub_rt_sigreturn)
+
+#define __NR_ioctl 16
+__SYSCALL(__NR_ioctl, sys_ioctl)
+#define __NR_pread64 17
+__SYSCALL(__NR_pread64, sys_pread64)
+#define __NR_pwrite64 18
+__SYSCALL(__NR_pwrite64, sys_pwrite64)
+#define __NR_readv 19
+__SYSCALL(__NR_readv, sys_readv)
+#define __NR_writev 20
+__SYSCALL(__NR_writev, sys_writev)
+#define __NR_access 21
+__SYSCALL(__NR_access, sys_access)
+#define __NR_pipe 22
+__SYSCALL(__NR_pipe, sys_pipe)
+#define __NR_select 23
+__SYSCALL(__NR_select, sys_select)
+
+#define __NR_sched_yield 24
+__SYSCALL(__NR_sched_yield, sys_sched_yield)
+#define __NR_mremap 25
+__SYSCALL(__NR_mremap, sys_mremap)
+#define __NR_msync 26
+__SYSCALL(__NR_msync, sys_msync)
+#define __NR_mincore 27
+__SYSCALL(__NR_mincore, sys_mincore)
+#define __NR_madvise 28
+__SYSCALL(__NR_madvise, sys_madvise)
+#define __NR_shmget 29
+__SYSCALL(__NR_shmget, sys_shmget)
+#define __NR_shmat 30
+__SYSCALL(__NR_shmat, sys_shmat)
+#define __NR_shmctl 31
+__SYSCALL(__NR_shmctl, sys_shmctl)
+
+#define __NR_dup 32
+__SYSCALL(__NR_dup, sys_dup)
+#define __NR_dup2 33
+__SYSCALL(__NR_dup2, sys_dup2)
+#define __NR_pause 34
+__SYSCALL(__NR_pause, sys_pause)
+#define __NR_nanosleep 35
+__SYSCALL(__NR_nanosleep, sys_nanosleep)
+#define __NR_getitimer 36
+__SYSCALL(__NR_getitimer, sys_getitimer)
+#define __NR_alarm 37
+__SYSCALL(__NR_alarm, sys_alarm)
+#define __NR_setitimer 38
+__SYSCALL(__NR_setitimer, sys_setitimer)
+#define __NR_getpid 39
+__SYSCALL(__NR_getpid, sys_getpid)
+
+#define __NR_sendfile 40
+__SYSCALL(__NR_sendfile, sys_sendfile64)
+#define __NR_socket 41
+__SYSCALL(__NR_socket, sys_socket)
+#define __NR_connect 42
+__SYSCALL(__NR_connect, sys_connect)
+#define __NR_accept 43
+__SYSCALL(__NR_accept, sys_accept)
+#define __NR_sendto 44
+__SYSCALL(__NR_sendto, sys_sendto)
+#define __NR_recvfrom 45
+__SYSCALL(__NR_recvfrom, sys_recvfrom)
+#define __NR_sendmsg 46
+__SYSCALL(__NR_sendmsg, sys_sendmsg)
+#define __NR_recvmsg 47
+__SYSCALL(__NR_recvmsg, sys_recvmsg)
+
+#define __NR_shutdown 48
+__SYSCALL(__NR_shutdown, sys_shutdown)
+#define __NR_bind 49
+__SYSCALL(__NR_bind, sys_bind)
+#define __NR_listen 50
+__SYSCALL(__NR_listen, sys_listen)
+#define __NR_getsockname 51
+__SYSCALL(__NR_getsockname, sys_getsockname)
+#define __NR_getpeername 52
+__SYSCALL(__NR_getpeername, sys_getpeername)
+#define __NR_socketpair 53
+__SYSCALL(__NR_socketpair, sys_socketpair)
+#define __NR_setsockopt 54
+__SYSCALL(__NR_setsockopt, sys_setsockopt)
+#define __NR_getsockopt 55
+__SYSCALL(__NR_getsockopt, sys_getsockopt)
+
+#define __NR_clone 56
+__SYSCALL(__NR_clone, stub_clone)
+#define __NR_fork 57
+__SYSCALL(__NR_fork, stub_fork)
+#define __NR_vfork 58
+__SYSCALL(__NR_vfork, stub_vfork)
+#define __NR_execve 59
+__SYSCALL(__NR_execve, stub_execve)
+#define __NR_exit 60
+__SYSCALL(__NR_exit, sys_exit)
+#define __NR_wait4 61
+__SYSCALL(__NR_wait4, sys_wait4)
+#define __NR_kill 62
+__SYSCALL(__NR_kill, sys_kill)
+#define __NR_uname 63
+__SYSCALL(__NR_uname, sys_newuname)
+
+#define __NR_semget 64
+__SYSCALL(__NR_semget, sys_semget)
+#define __NR_semop 65
+__SYSCALL(__NR_semop, sys_semop)
+#define __NR_semctl 66
+__SYSCALL(__NR_semctl, sys_semctl)
+#define __NR_shmdt 67
+__SYSCALL(__NR_shmdt, sys_shmdt)
+#define __NR_msgget 68
+__SYSCALL(__NR_msgget, sys_msgget)
+#define __NR_msgsnd 69
+__SYSCALL(__NR_msgsnd, sys_msgsnd)
+#define __NR_msgrcv 70
+__SYSCALL(__NR_msgrcv, sys_msgrcv)
+#define __NR_msgctl 71
+__SYSCALL(__NR_msgctl, sys_msgctl)
+
+#define __NR_fcntl 72
+__SYSCALL(__NR_fcntl, sys_fcntl)
+#define __NR_flock 73
+__SYSCALL(__NR_flock, sys_flock)
+#define __NR_fsync 74
+__SYSCALL(__NR_fsync, sys_fsync)
+#define __NR_fdatasync 75
+__SYSCALL(__NR_fdatasync, sys_fdatasync)
+#define __NR_truncate 76
+__SYSCALL(__NR_truncate, sys_truncate)
+#define __NR_ftruncate 77
+__SYSCALL(__NR_ftruncate, sys_ftruncate)
+#define __NR_getdents 78
+__SYSCALL(__NR_getdents, sys_getdents)
+#define __NR_getcwd 79
+__SYSCALL(__NR_getcwd, sys_getcwd)
+
+#define __NR_chdir 80
+__SYSCALL(__NR_chdir, sys_chdir)
+#define __NR_fchdir 81
+__SYSCALL(__NR_fchdir, sys_fchdir)
+#define __NR_rename 82
+__SYSCALL(__NR_rename, sys_rename)
+#define __NR_mkdir 83
+__SYSCALL(__NR_mkdir, sys_mkdir)
+#define __NR_rmdir 84
+__SYSCALL(__NR_rmdir, sys_rmdir)
+#define __NR_creat 85
+__SYSCALL(__NR_creat, sys_creat)
+#define __NR_link 86
+__SYSCALL(__NR_link, sys_link)
+#define __NR_unlink 87
+__SYSCALL(__NR_unlink, sys_unlink)
+
+#define __NR_symlink 88
+__SYSCALL(__NR_symlink, sys_symlink)
+#define __NR_readlink 89
+__SYSCALL(__NR_readlink, sys_readlink)
+#define __NR_chmod 90
+__SYSCALL(__NR_chmod, sys_chmod)
+#define __NR_fchmod 91
+__SYSCALL(__NR_fchmod, sys_fchmod)
+#define __NR_chown 92
+__SYSCALL(__NR_chown, sys_chown)
+#define __NR_fchown 93
+__SYSCALL(__NR_fchown, sys_fchown)
+#define __NR_lchown 94
+__SYSCALL(__NR_lchown, sys_lchown)
+#define __NR_umask 95
+__SYSCALL(__NR_umask, sys_umask)
+
+#define __NR_gettimeofday 96
+__SYSCALL(__NR_gettimeofday, sys_gettimeofday)
+#define __NR_getrlimit 97
+__SYSCALL(__NR_getrlimit, sys_getrlimit)
+#define __NR_getrusage 98
+__SYSCALL(__NR_getrusage, sys_getrusage)
+#define __NR_sysinfo 99
+__SYSCALL(__NR_sysinfo, sys_sysinfo)
+#define __NR_times 100
+__SYSCALL(__NR_times, sys_times)
+#define __NR_ptrace 101
+__SYSCALL(__NR_ptrace, sys_ptrace)
+#define __NR_getuid 102
+__SYSCALL(__NR_getuid, sys_getuid)
+#define __NR_syslog 103
+__SYSCALL(__NR_syslog, sys_syslog)
+
+/* at the very end the stuff that never runs during the benchmarks */
+#define __NR_getgid 104
+__SYSCALL(__NR_getgid, sys_getgid)
+#define __NR_setuid 105
+__SYSCALL(__NR_setuid, sys_setuid)
+#define __NR_setgid 106
+__SYSCALL(__NR_setgid, sys_setgid)
+#define __NR_geteuid 107
+__SYSCALL(__NR_geteuid, sys_geteuid)
+#define __NR_getegid 108
+__SYSCALL(__NR_getegid, sys_getegid)
+#define __NR_setpgid 109
+__SYSCALL(__NR_setpgid, sys_setpgid)
+#define __NR_getppid 110
+__SYSCALL(__NR_getppid, sys_getppid)
+#define __NR_getpgrp 111
+__SYSCALL(__NR_getpgrp, sys_getpgrp)
+
+#define __NR_setsid 112
+__SYSCALL(__NR_setsid, sys_setsid)
+#define __NR_setreuid 113
+__SYSCALL(__NR_setreuid, sys_setreuid)
+#define __NR_setregid 114
+__SYSCALL(__NR_setregid, sys_setregid)
+#define __NR_getgroups 115
+__SYSCALL(__NR_getgroups, sys_getgroups)
+#define __NR_setgroups 116
+__SYSCALL(__NR_setgroups, sys_setgroups)
+#define __NR_setresuid 117
+__SYSCALL(__NR_setresuid, sys_setresuid)
+#define __NR_getresuid 118
+__SYSCALL(__NR_getresuid, sys_getresuid)
+#define __NR_setresgid 119
+__SYSCALL(__NR_setresgid, sys_setresgid)
+
+#define __NR_getresgid 120
+__SYSCALL(__NR_getresgid, sys_getresgid)
+#define __NR_getpgid 121
+__SYSCALL(__NR_getpgid, sys_getpgid)
+#define __NR_setfsuid 122
+__SYSCALL(__NR_setfsuid, sys_setfsuid)
+#define __NR_setfsgid 123
+__SYSCALL(__NR_setfsgid, sys_setfsgid)
+#define __NR_getsid 124
+__SYSCALL(__NR_getsid, sys_getsid)
+#define __NR_capget 125
+__SYSCALL(__NR_capget, sys_capget)
+#define __NR_capset 126
+__SYSCALL(__NR_capset, sys_capset)
+
+#define __NR_rt_sigpending 127
+__SYSCALL(__NR_rt_sigpending, sys_rt_sigpending)
+#define __NR_rt_sigtimedwait 128
+__SYSCALL(__NR_rt_sigtimedwait, sys_rt_sigtimedwait)
+#define __NR_rt_sigqueueinfo 129
+__SYSCALL(__NR_rt_sigqueueinfo, sys_rt_sigqueueinfo)
+#define __NR_rt_sigsuspend 130
+__SYSCALL(__NR_rt_sigsuspend, sys_rt_sigsuspend)
+#define __NR_sigaltstack 131
+__SYSCALL(__NR_sigaltstack, stub_sigaltstack)
+#define __NR_utime 132
+__SYSCALL(__NR_utime, sys_utime)
+#define __NR_mknod 133
+__SYSCALL(__NR_mknod, sys_mknod)
+
+/* Only needed for a.out */
+#define __NR_uselib 134
+__SYSCALL(__NR_uselib, sys_ni_syscall)
+#define __NR_personality 135
+__SYSCALL(__NR_personality, sys_personality)
+
+#define __NR_ustat 136
+__SYSCALL(__NR_ustat, sys_ustat)
+#define __NR_statfs 137
+__SYSCALL(__NR_statfs, sys_statfs)
+#define __NR_fstatfs 138
+__SYSCALL(__NR_fstatfs, sys_fstatfs)
+#define __NR_sysfs 139
+__SYSCALL(__NR_sysfs, sys_sysfs)
+
+#define __NR_getpriority 140
+__SYSCALL(__NR_getpriority, sys_getpriority)
+#define __NR_setpriority 141
+__SYSCALL(__NR_setpriority, sys_setpriority)
+#define __NR_sched_setparam 142
+__SYSCALL(__NR_sched_setparam, sys_sched_setparam)
+#define __NR_sched_getparam 143
+__SYSCALL(__NR_sched_getparam, sys_sched_getparam)
+#define __NR_sched_setscheduler 144
+__SYSCALL(__NR_sched_setscheduler, sys_sched_setscheduler)
+#define __NR_sched_getscheduler 145
+__SYSCALL(__NR_sched_getscheduler, sys_sched_getscheduler)
+#define __NR_sched_get_priority_max 146
+__SYSCALL(__NR_sched_get_priority_max, sys_sched_get_priority_max)
+#define __NR_sched_get_priority_min 147
+__SYSCALL(__NR_sched_get_priority_min, sys_sched_get_priority_min)
+#define __NR_sched_rr_get_interval 148
+__SYSCALL(__NR_sched_rr_get_interval, sys_sched_rr_get_interval)
+
+#define __NR_mlock 149
+__SYSCALL(__NR_mlock, sys_mlock)
+#define __NR_munlock 150
+__SYSCALL(__NR_munlock, sys_munlock)
+#define __NR_mlockall 151
+__SYSCALL(__NR_mlockall, sys_mlockall)
+#define __NR_munlockall 152
+__SYSCALL(__NR_munlockall, sys_munlockall)
+
+#define __NR_vhangup 153
+__SYSCALL(__NR_vhangup, sys_vhangup)
+
+#define __NR_modify_ldt 154
+__SYSCALL(__NR_modify_ldt, sys_modify_ldt)
+
+#define __NR_pivot_root 155
+__SYSCALL(__NR_pivot_root, sys_pivot_root)
+
+#define __NR__sysctl 156
+__SYSCALL(__NR__sysctl, sys_sysctl)
+
+#define __NR_prctl 157
+__SYSCALL(__NR_prctl, sys_prctl)
+#define __NR_arch_prctl 158
+__SYSCALL(__NR_arch_prctl, sys_arch_prctl)
+
+#define __NR_adjtimex 159
+__SYSCALL(__NR_adjtimex, sys_adjtimex)
+
+#define __NR_setrlimit 160
+__SYSCALL(__NR_setrlimit, sys_setrlimit)
+
+#define __NR_chroot 161
+__SYSCALL(__NR_chroot, sys_chroot)
+
+#define __NR_sync 162
+__SYSCALL(__NR_sync, sys_sync)
+
+#define __NR_acct 163
+__SYSCALL(__NR_acct, sys_acct)
+
+#define __NR_settimeofday 164
+__SYSCALL(__NR_settimeofday, sys_settimeofday)
+
+#define __NR_mount 165
+__SYSCALL(__NR_mount, sys_mount)
+#define __NR_umount2 166
+__SYSCALL(__NR_umount2, sys_umount)
+
+#define __NR_swapon 167
+__SYSCALL(__NR_swapon, sys_swapon)
+#define __NR_swapoff 168
+__SYSCALL(__NR_swapoff, sys_swapoff)
+
+#define __NR_reboot 169
+__SYSCALL(__NR_reboot, sys_reboot)
+
+#define __NR_sethostname 170
+__SYSCALL(__NR_sethostname, sys_sethostname)
+#define __NR_setdomainname 171
+__SYSCALL(__NR_setdomainname, sys_setdomainname)
+
+#define __NR_iopl 172
+__SYSCALL(__NR_iopl, stub_iopl)
+#define __NR_ioperm 173
+__SYSCALL(__NR_ioperm, sys_ioperm)
+
+#define __NR_create_module 174
+__SYSCALL(__NR_create_module, sys_ni_syscall)
+#define __NR_init_module 175
+__SYSCALL(__NR_init_module, sys_init_module)
+#define __NR_delete_module 176
+__SYSCALL(__NR_delete_module, sys_delete_module)
+#define __NR_get_kernel_syms 177
+__SYSCALL(__NR_get_kernel_syms, sys_ni_syscall)
+#define __NR_query_module 178
+__SYSCALL(__NR_query_module, sys_ni_syscall)
+
+#define __NR_quotactl 179
+__SYSCALL(__NR_quotactl, sys_quotactl)
+
+#define __NR_nfsservctl 180
+__SYSCALL(__NR_nfsservctl, sys_ni_syscall)
+
+/* reserved for LiS/STREAMS */
+#define __NR_getpmsg 181
+__SYSCALL(__NR_getpmsg, sys_ni_syscall)
+#define __NR_putpmsg 182
+__SYSCALL(__NR_putpmsg, sys_ni_syscall)
+
+/* reserved for AFS */
+#define __NR_afs_syscall 183
+__SYSCALL(__NR_afs_syscall, sys_ni_syscall)
+
+/* reserved for tux */
+#define __NR_tuxcall 184
+__SYSCALL(__NR_tuxcall, sys_ni_syscall)
+
+#define __NR_security 185
+__SYSCALL(__NR_security, sys_ni_syscall)
+
+#define __NR_gettid 186
+__SYSCALL(__NR_gettid, sys_gettid)
+
+#define __NR_readahead 187
+__SYSCALL(__NR_readahead, sys_readahead)
+#define __NR_setxattr 188
+__SYSCALL(__NR_setxattr, sys_setxattr)
+#define __NR_lsetxattr 189
+__SYSCALL(__NR_lsetxattr, sys_lsetxattr)
+#define __NR_fsetxattr 190
+__SYSCALL(__NR_fsetxattr, sys_fsetxattr)
+#define __NR_getxattr 191
+__SYSCALL(__NR_getxattr, sys_getxattr)
+#define __NR_lgetxattr 192
+__SYSCALL(__NR_lgetxattr, sys_lgetxattr)
+#define __NR_fgetxattr 193
+__SYSCALL(__NR_fgetxattr, sys_fgetxattr)
+#define __NR_listxattr 194
+__SYSCALL(__NR_listxattr, sys_listxattr)
+#define __NR_llistxattr 195
+__SYSCALL(__NR_llistxattr, sys_llistxattr)
+#define __NR_flistxattr 196
+__SYSCALL(__NR_flistxattr, sys_flistxattr)
+#define __NR_removexattr 197
+__SYSCALL(__NR_removexattr, sys_removexattr)
+#define __NR_lremovexattr 198
+__SYSCALL(__NR_lremovexattr, sys_lremovexattr)
+#define __NR_fremovexattr 199
+__SYSCALL(__NR_fremovexattr, sys_fremovexattr)
+#define __NR_tkill 200
+__SYSCALL(__NR_tkill, sys_tkill)
+#define __NR_time 201
+__SYSCALL(__NR_time, sys_time)
+#define __NR_futex 202
+__SYSCALL(__NR_futex, sys_futex)
+#define __NR_sched_setaffinity 203
+__SYSCALL(__NR_sched_setaffinity, sys_sched_setaffinity)
+#define __NR_sched_getaffinity 204
+__SYSCALL(__NR_sched_getaffinity, sys_sched_getaffinity)
+#define __NR_set_thread_area 205
+__SYSCALL(__NR_set_thread_area, sys_ni_syscall) /* use arch_prctl */
+#define __NR_io_setup 206
+__SYSCALL(__NR_io_setup, sys_io_setup)
+#define __NR_io_destroy 207
+__SYSCALL(__NR_io_destroy, sys_io_destroy)
+#define __NR_io_getevents 208
+__SYSCALL(__NR_io_getevents, sys_io_getevents)
+#define __NR_io_submit 209
+__SYSCALL(__NR_io_submit, sys_io_submit)
+#define __NR_io_cancel 210
+__SYSCALL(__NR_io_cancel, sys_io_cancel)
+#define __NR_get_thread_area 211
+__SYSCALL(__NR_get_thread_area, sys_ni_syscall) /* use arch_prctl */
+#define __NR_lookup_dcookie 212
+__SYSCALL(__NR_lookup_dcookie, sys_lookup_dcookie)
+#define __NR_epoll_create 213
+__SYSCALL(__NR_epoll_create, sys_epoll_create)
+#define __NR_epoll_ctl_old 214
+__SYSCALL(__NR_epoll_ctl_old, sys_ni_syscall)
+#define __NR_epoll_wait_old 215
+__SYSCALL(__NR_epoll_wait_old, sys_ni_syscall)
+#define __NR_remap_file_pages 216
+__SYSCALL(__NR_remap_file_pages, sys_remap_file_pages)
+#define __NR_getdents64 217
+__SYSCALL(__NR_getdents64, sys_getdents64)
+#define __NR_set_tid_address 218
+__SYSCALL(__NR_set_tid_address, sys_set_tid_address)
+#define __NR_restart_syscall 219
+__SYSCALL(__NR_restart_syscall, sys_restart_syscall)
+#define __NR_semtimedop 220
+__SYSCALL(__NR_semtimedop, sys_semtimedop)
+#define __NR_fadvise64 221
+__SYSCALL(__NR_fadvise64, sys_fadvise64)
+#define __NR_timer_create 222
+__SYSCALL(__NR_timer_create, sys_timer_create)
+#define __NR_timer_settime 223
+__SYSCALL(__NR_timer_settime, sys_timer_settime)
+#define __NR_timer_gettime 224
+__SYSCALL(__NR_timer_gettime, sys_timer_gettime)
+#define __NR_timer_getoverrun 225
+__SYSCALL(__NR_timer_getoverrun, sys_timer_getoverrun)
+#define __NR_timer_delete 226
+__SYSCALL(__NR_timer_delete, sys_timer_delete)
+#define __NR_clock_settime 227
+__SYSCALL(__NR_clock_settime, sys_clock_settime)
+#define __NR_clock_gettime 228
+__SYSCALL(__NR_clock_gettime, sys_clock_gettime)
+#define __NR_clock_getres 229
+__SYSCALL(__NR_clock_getres, sys_clock_getres)
+#define __NR_clock_nanosleep 230
+__SYSCALL(__NR_clock_nanosleep, sys_clock_nanosleep)
+#define __NR_exit_group 231
+__SYSCALL(__NR_exit_group, sys_exit_group)
+#define __NR_epoll_wait 232
+__SYSCALL(__NR_epoll_wait, sys_epoll_wait)
+#define __NR_epoll_ctl 233
+__SYSCALL(__NR_epoll_ctl, sys_epoll_ctl)
+#define __NR_tgkill 234
+__SYSCALL(__NR_tgkill, sys_tgkill)
+#define __NR_utimes 235
+__SYSCALL(__NR_utimes, sys_utimes)
+#define __NR_vserver 236
+__SYSCALL(__NR_vserver, sys_ni_syscall)
+#define __NR_mbind 237
+__SYSCALL(__NR_mbind, sys_mbind)
+#define __NR_set_mempolicy 238
+__SYSCALL(__NR_set_mempolicy, sys_set_mempolicy)
+#define __NR_get_mempolicy 239
+__SYSCALL(__NR_get_mempolicy, sys_get_mempolicy)
+#define __NR_mq_open 240
+__SYSCALL(__NR_mq_open, sys_mq_open)
+#define __NR_mq_unlink 241
+__SYSCALL(__NR_mq_unlink, sys_mq_unlink)
+#define __NR_mq_timedsend 242
+__SYSCALL(__NR_mq_timedsend, sys_mq_timedsend)
+#define __NR_mq_timedreceive 243
+__SYSCALL(__NR_mq_timedreceive, sys_mq_timedreceive)
+#define __NR_mq_notify 244
+__SYSCALL(__NR_mq_notify, sys_mq_notify)
+#define __NR_mq_getsetattr 245
+__SYSCALL(__NR_mq_getsetattr, sys_mq_getsetattr)
+#define __NR_kexec_load 246
+__SYSCALL(__NR_kexec_load, sys_kexec_load)
+#define __NR_waitid 247
+__SYSCALL(__NR_waitid, sys_waitid)
+#define __NR_add_key 248
+__SYSCALL(__NR_add_key, sys_add_key)
+#define __NR_request_key 249
+__SYSCALL(__NR_request_key, sys_request_key)
+#define __NR_keyctl 250
+__SYSCALL(__NR_keyctl, sys_keyctl)
+#define __NR_ioprio_set 251
+__SYSCALL(__NR_ioprio_set, sys_ioprio_set)
+#define __NR_ioprio_get 252
+__SYSCALL(__NR_ioprio_get, sys_ioprio_get)
+#define __NR_inotify_init 253
+__SYSCALL(__NR_inotify_init, sys_inotify_init)
+#define __NR_inotify_add_watch 254
+__SYSCALL(__NR_inotify_add_watch, sys_inotify_add_watch)
+#define __NR_inotify_rm_watch 255
+__SYSCALL(__NR_inotify_rm_watch, sys_inotify_rm_watch)
+#define __NR_migrate_pages 256
+__SYSCALL(__NR_migrate_pages, sys_migrate_pages)
+#define __NR_openat 257
+__SYSCALL(__NR_openat, sys_openat)
+#define __NR_mkdirat 258
+__SYSCALL(__NR_mkdirat, sys_mkdirat)
+#define __NR_mknodat 259
+__SYSCALL(__NR_mknodat, sys_mknodat)
+#define __NR_fchownat 260
+__SYSCALL(__NR_fchownat, sys_fchownat)
+#define __NR_futimesat 261
+__SYSCALL(__NR_futimesat, sys_futimesat)
+#define __NR_newfstatat 262
+__SYSCALL(__NR_newfstatat, sys_newfstatat)
+#define __NR_unlinkat 263
+__SYSCALL(__NR_unlinkat, sys_unlinkat)
+#define __NR_renameat 264
+__SYSCALL(__NR_renameat, sys_renameat)
+#define __NR_linkat 265
+__SYSCALL(__NR_linkat, sys_linkat)
+#define __NR_symlinkat 266
+__SYSCALL(__NR_symlinkat, sys_symlinkat)
+#define __NR_readlinkat 267
+__SYSCALL(__NR_readlinkat, sys_readlinkat)
+#define __NR_fchmodat 268
+__SYSCALL(__NR_fchmodat, sys_fchmodat)
+#define __NR_faccessat 269
+__SYSCALL(__NR_faccessat, sys_faccessat)
+#define __NR_pselect6 270
+__SYSCALL(__NR_pselect6, sys_pselect6)
+#define __NR_ppoll 271
+__SYSCALL(__NR_ppoll, sys_ppoll)
+#define __NR_unshare 272
+__SYSCALL(__NR_unshare, sys_unshare)
+#define __NR_set_robust_list 273
+__SYSCALL(__NR_set_robust_list, sys_set_robust_list)
+#define __NR_get_robust_list 274
+__SYSCALL(__NR_get_robust_list, sys_get_robust_list)
+#define __NR_splice 275
+__SYSCALL(__NR_splice, sys_splice)
+#define __NR_tee 276
+__SYSCALL(__NR_tee, sys_tee)
+#define __NR_sync_file_range 277
+__SYSCALL(__NR_sync_file_range, sys_sync_file_range)
+#define __NR_vmsplice 278
+__SYSCALL(__NR_vmsplice, sys_vmsplice)
+#define __NR_move_pages 279
+__SYSCALL(__NR_move_pages, sys_move_pages)
+#define __NR_utimensat 280
+__SYSCALL(__NR_utimensat, sys_utimensat)
+#define __NR_epoll_pwait 281
+__SYSCALL(__NR_epoll_pwait, sys_epoll_pwait)
+#define __NR_signalfd 282
+__SYSCALL(__NR_signalfd, sys_signalfd)
+#define __NR_timerfd_create 283
+__SYSCALL(__NR_timerfd_create, sys_timerfd_create)
+#define __NR_eventfd 284
+__SYSCALL(__NR_eventfd, sys_eventfd)
+#define __NR_fallocate 285
+__SYSCALL(__NR_fallocate, sys_fallocate)
+#define __NR_timerfd_settime 286
+__SYSCALL(__NR_timerfd_settime, sys_timerfd_settime)
+#define __NR_timerfd_gettime 287
+__SYSCALL(__NR_timerfd_gettime, sys_timerfd_gettime)
+#define __NR_accept4 288
+__SYSCALL(__NR_accept4, sys_accept4)
+#define __NR_signalfd4 289
+__SYSCALL(__NR_signalfd4, sys_signalfd4)
+#define __NR_eventfd2 290
+__SYSCALL(__NR_eventfd2, sys_eventfd2)
+#define __NR_epoll_create1 291
+__SYSCALL(__NR_epoll_create1, sys_epoll_create1)
+#define __NR_dup3 292
+__SYSCALL(__NR_dup3, sys_dup3)
+#define __NR_pipe2 293
+__SYSCALL(__NR_pipe2, sys_pipe2)
+#define __NR_inotify_init1 294
+__SYSCALL(__NR_inotify_init1, sys_inotify_init1)
+#define __NR_preadv 295
+__SYSCALL(__NR_preadv, sys_preadv)
+#define __NR_pwritev 296
+__SYSCALL(__NR_pwritev, sys_pwritev)
+#define __NR_rt_tgsigqueueinfo 297
+__SYSCALL(__NR_rt_tgsigqueueinfo, sys_rt_tgsigqueueinfo)
+#define __NR_perf_event_open 298
+__SYSCALL(__NR_perf_event_open, sys_perf_event_open)
+#define __NR_recvmmsg 299
+__SYSCALL(__NR_recvmmsg, sys_recvmmsg)
+#define __NR_fanotify_init 300
+__SYSCALL(__NR_fanotify_init, sys_fanotify_init)
+#define __NR_fanotify_mark 301
+__SYSCALL(__NR_fanotify_mark, sys_fanotify_mark)
+#define __NR_prlimit64 302
+__SYSCALL(__NR_prlimit64, sys_prlimit64)
+#define __NR_name_to_handle_at 303
+__SYSCALL(__NR_name_to_handle_at, sys_name_to_handle_at)
+#define __NR_open_by_handle_at 304
+__SYSCALL(__NR_open_by_handle_at, sys_open_by_handle_at)
+#define __NR_clock_adjtime 305
+__SYSCALL(__NR_clock_adjtime, sys_clock_adjtime)
+#define __NR_syncfs 306
+__SYSCALL(__NR_syncfs, sys_syncfs)
+#define __NR_sendmmsg 307
+__SYSCALL(__NR_sendmmsg, sys_sendmmsg)
+#define __NR_setns 308
+__SYSCALL(__NR_setns, sys_setns)
+#define __NR_getcpu 309
+__SYSCALL(__NR_getcpu, sys_getcpu)
+#define __NR_process_vm_readv 310
+__SYSCALL(__NR_process_vm_readv, sys_process_vm_readv)
+#define __NR_process_vm_writev 311
+__SYSCALL(__NR_process_vm_writev, sys_process_vm_writev)
+
+#ifndef __NO_STUBS
+#define __ARCH_WANT_OLD_READDIR
+#define __ARCH_WANT_OLD_STAT
+#define __ARCH_WANT_SYS_ALARM
+#define __ARCH_WANT_SYS_GETHOSTNAME
+#define __ARCH_WANT_SYS_PAUSE
+#define __ARCH_WANT_SYS_SGETMASK
+#define __ARCH_WANT_SYS_SIGNAL
+#define __ARCH_WANT_SYS_UTIME
+#define __ARCH_WANT_SYS_WAITPID
+#define __ARCH_WANT_SYS_SOCKETCALL
+#define __ARCH_WANT_SYS_FADVISE64
+#define __ARCH_WANT_SYS_GETPGRP
+#define __ARCH_WANT_SYS_LLSEEK
+#define __ARCH_WANT_SYS_NICE
+#define __ARCH_WANT_SYS_OLD_GETRLIMIT
+#define __ARCH_WANT_SYS_OLD_UNAME
+#define __ARCH_WANT_SYS_OLDUMOUNT
+#define __ARCH_WANT_SYS_SIGPENDING
+#define __ARCH_WANT_SYS_SIGPROCMASK
+#define __ARCH_WANT_SYS_RT_SIGACTION
+#define __ARCH_WANT_SYS_RT_SIGSUSPEND
+#define __ARCH_WANT_SYS_TIME
+#define __ARCH_WANT_COMPAT_SYS_TIME
+#endif /* __NO_STUBS */
+
+#ifdef __KERNEL__
+
+#ifndef COMPILE_OFFSETS
+#include
+#define NR_syscalls (__NR_syscall_max + 1)
+#endif
+
+/*
+ * "Conditional" syscalls
+ *
+ * What we want is __attribute__((weak,alias("sys_ni_syscall"))),
+ * but it doesn't work on all toolchains, so we just do it by hand
+ */
+#define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall")
+#endif /* __KERNEL__ */
+
+#endif /* _ASM_X86_UNISTD_64_H */
diff --git a/trunk/arch/x86/kernel/Makefile b/trunk/arch/x86/kernel/Makefile
index 5369059c07a9..02b2f05b371e 100644
--- a/trunk/arch/x86/kernel/Makefile
+++ b/trunk/arch/x86/kernel/Makefile
@@ -25,8 +25,7 @@ obj-$(CONFIG_IRQ_WORK) += irq_work.o
obj-y += probe_roms.o
obj-$(CONFIG_X86_32) += sys_i386_32.o i386_ksyms_32.o
obj-$(CONFIG_X86_64) += sys_x86_64.o x8664_ksyms_64.o
-obj-y += syscall_$(BITS).o
-obj-$(CONFIG_X86_64) += vsyscall_64.o
+obj-$(CONFIG_X86_64) += syscall_64.o vsyscall_64.o
obj-$(CONFIG_X86_64) += vsyscall_emu_64.o
obj-y += bootflag.o e820.o
obj-y += pci-dma.o quirks.o topology.o kdebugfs.o
diff --git a/trunk/arch/x86/kernel/asm-offsets_32.c b/trunk/arch/x86/kernel/asm-offsets_32.c
index 85d98ab15cdc..395a10e68067 100644
--- a/trunk/arch/x86/kernel/asm-offsets_32.c
+++ b/trunk/arch/x86/kernel/asm-offsets_32.c
@@ -3,11 +3,6 @@
#include
#include "../../../drivers/lguest/lg.h"
-#define __SYSCALL_I386(nr, sym, compat) [nr] = 1,
-static char syscalls[] = {
-#include
-};
-
/* workaround for a warning with -Wmissing-prototypes */
void foo(void);
@@ -81,7 +76,4 @@ void foo(void)
OFFSET(LGUEST_PAGES_regs_errcode, lguest_pages, regs.errcode);
OFFSET(LGUEST_PAGES_regs, lguest_pages, regs);
#endif
- BLANK();
- DEFINE(__NR_syscall_max, sizeof(syscalls) - 1);
- DEFINE(NR_syscalls, sizeof(syscalls));
}
diff --git a/trunk/arch/x86/kernel/asm-offsets_64.c b/trunk/arch/x86/kernel/asm-offsets_64.c
index 834e897b1e25..e72a1194af22 100644
--- a/trunk/arch/x86/kernel/asm-offsets_64.c
+++ b/trunk/arch/x86/kernel/asm-offsets_64.c
@@ -1,12 +1,11 @@
#include
-#define __SYSCALL_64(nr, sym, compat) [nr] = 1,
-static char syscalls_64[] = {
-#include
-};
-#define __SYSCALL_I386(nr, sym, compat) [nr] = 1,
-static char syscalls_ia32[] = {
-#include
+#define __NO_STUBS 1
+#undef __SYSCALL
+#undef _ASM_X86_UNISTD_64_H
+#define __SYSCALL(nr, sym) [nr] = 1,
+static char syscalls[] = {
+#include
};
int main(void)
@@ -73,11 +72,7 @@ int main(void)
OFFSET(TSS_ist, tss_struct, x86_tss.ist);
BLANK();
- DEFINE(__NR_syscall_max, sizeof(syscalls_64) - 1);
- DEFINE(NR_syscalls, sizeof(syscalls_64));
-
- DEFINE(__NR_ia32_syscall_max, sizeof(syscalls_ia32) - 1);
- DEFINE(IA32_NR_syscalls, sizeof(syscalls_ia32));
+ DEFINE(__NR_syscall_max, sizeof(syscalls) - 1);
return 0;
}
diff --git a/trunk/arch/x86/kernel/cpu/mcheck/mce.c b/trunk/arch/x86/kernel/cpu/mcheck/mce.c
index 5a11ae2e9e91..29ba3297e480 100644
--- a/trunk/arch/x86/kernel/cpu/mcheck/mce.c
+++ b/trunk/arch/x86/kernel/cpu/mcheck/mce.c
@@ -1859,7 +1859,7 @@ static struct bus_type mce_subsys = {
.dev_name = "machinecheck",
};
-struct device *mce_device[CONFIG_NR_CPUS];
+DEFINE_PER_CPU(struct device, mce_device);
__cpuinitdata
void (*threshold_cpu_callback)(unsigned long action, unsigned int cpu);
@@ -2001,27 +2001,19 @@ static struct device_attribute *mce_device_attrs[] = {
static cpumask_var_t mce_device_initialized;
-static void mce_device_release(struct device *dev)
-{
- kfree(dev);
-}
-
/* Per cpu device init. All of the cpus still share the same ctrl bank: */
static __cpuinit int mce_device_create(unsigned int cpu)
{
- struct device *dev;
+ struct device *dev = &per_cpu(mce_device, cpu);
int err;
int i, j;
if (!mce_available(&boot_cpu_data))
return -EIO;
- dev = kzalloc(sizeof *dev, GFP_KERNEL);
- if (!dev)
- return -ENOMEM;
+ memset(dev, 0, sizeof(struct device));
dev->id = cpu;
dev->bus = &mce_subsys;
- dev->release = &mce_device_release;
err = device_register(dev);
if (err)
@@ -2038,7 +2030,6 @@ static __cpuinit int mce_device_create(unsigned int cpu)
goto error2;
}
cpumask_set_cpu(cpu, mce_device_initialized);
- mce_device[cpu] = dev;
return 0;
error2:
@@ -2055,7 +2046,7 @@ static __cpuinit int mce_device_create(unsigned int cpu)
static __cpuinit void mce_device_remove(unsigned int cpu)
{
- struct device *dev = mce_device[cpu];
+ struct device *dev = &per_cpu(mce_device, cpu);
int i;
if (!cpumask_test_cpu(cpu, mce_device_initialized))
@@ -2069,7 +2060,6 @@ static __cpuinit void mce_device_remove(unsigned int cpu)
device_unregister(dev);
cpumask_clear_cpu(cpu, mce_device_initialized);
- mce_device[cpu] = NULL;
}
/* Make sure there are no machine checks on offlined CPUs. */
diff --git a/trunk/arch/x86/kernel/cpu/mcheck/mce_amd.c b/trunk/arch/x86/kernel/cpu/mcheck/mce_amd.c
index 786e76a86322..ba0b94a7e204 100644
--- a/trunk/arch/x86/kernel/cpu/mcheck/mce_amd.c
+++ b/trunk/arch/x86/kernel/cpu/mcheck/mce_amd.c
@@ -523,7 +523,6 @@ static __cpuinit int threshold_create_bank(unsigned int cpu, unsigned int bank)
{
int i, err = 0;
struct threshold_bank *b = NULL;
- struct device *dev = mce_device[cpu];
char name[32];
sprintf(name, "threshold_bank%i", bank);
@@ -544,7 +543,8 @@ static __cpuinit int threshold_create_bank(unsigned int cpu, unsigned int bank)
if (!b)
goto out;
- err = sysfs_create_link(&dev->kobj, b->kobj, name);
+ err = sysfs_create_link(&per_cpu(mce_device, cpu).kobj,
+ b->kobj, name);
if (err)
goto out;
@@ -565,7 +565,7 @@ static __cpuinit int threshold_create_bank(unsigned int cpu, unsigned int bank)
goto out;
}
- b->kobj = kobject_create_and_add(name, &dev->kobj);
+ b->kobj = kobject_create_and_add(name, &per_cpu(mce_device, cpu).kobj);
if (!b->kobj)
goto out_free;
@@ -585,9 +585,8 @@ static __cpuinit int threshold_create_bank(unsigned int cpu, unsigned int bank)
if (i == cpu)
continue;
- dev = mce_device[i];
- if (dev)
- err = sysfs_create_link(&dev->kobj,b->kobj, name);
+ err = sysfs_create_link(&per_cpu(mce_device, i).kobj,
+ b->kobj, name);
if (err)
goto out;
@@ -650,7 +649,6 @@ static void deallocate_threshold_block(unsigned int cpu,
static void threshold_remove_bank(unsigned int cpu, int bank)
{
struct threshold_bank *b;
- struct device *dev;
char name[32];
int i = 0;
@@ -665,7 +663,7 @@ static void threshold_remove_bank(unsigned int cpu, int bank)
#ifdef CONFIG_SMP
/* sibling symlink */
if (shared_bank[bank] && b->blocks->cpu != cpu) {
- sysfs_remove_link(&mce_device[cpu]->kobj, name);
+ sysfs_remove_link(&per_cpu(mce_device, cpu).kobj, name);
per_cpu(threshold_banks, cpu)[bank] = NULL;
return;
@@ -677,9 +675,7 @@ static void threshold_remove_bank(unsigned int cpu, int bank)
if (i == cpu)
continue;
- dev = mce_device[i];
- if (dev)
- sysfs_remove_link(&dev->kobj, name);
+ sysfs_remove_link(&per_cpu(mce_device, i).kobj, name);
per_cpu(threshold_banks, i)[bank] = NULL;
}
diff --git a/trunk/arch/x86/kernel/e820.c b/trunk/arch/x86/kernel/e820.c
index 62d61e9976eb..174d938d576b 100644
--- a/trunk/arch/x86/kernel/e820.c
+++ b/trunk/arch/x86/kernel/e820.c
@@ -703,7 +703,7 @@ void __init e820_mark_nosave_regions(unsigned long limit_pfn)
}
#endif
-#ifdef CONFIG_ACPI
+#ifdef CONFIG_HIBERNATION
/**
* Mark ACPI NVS memory region, so that we can save/restore it during
* hibernation and the subsequent resume.
@@ -716,7 +716,7 @@ static int __init e820_mark_nvs_memory(void)
struct e820entry *ei = &e820.map[i];
if (ei->type == E820_NVS)
- acpi_nvs_register(ei->addr, ei->size);
+ suspend_nvs_register(ei->addr, ei->size);
}
return 0;
diff --git a/trunk/arch/x86/kernel/entry_32.S b/trunk/arch/x86/kernel/entry_32.S
index 79d97e68f042..22d0e21b4dd7 100644
--- a/trunk/arch/x86/kernel/entry_32.S
+++ b/trunk/arch/x86/kernel/entry_32.S
@@ -42,7 +42,6 @@
*/
#include
-#include
#include
#include
#include
@@ -82,6 +81,8 @@
* enough to patch inline, increasing performance.
*/
+#define nr_syscalls ((syscall_table_size)/4)
+
#ifdef CONFIG_PREEMPT
#define preempt_stop(clobbers) DISABLE_INTERRUPTS(clobbers); TRACE_IRQS_OFF
#else
@@ -422,7 +423,7 @@ sysenter_past_esp:
testl $_TIF_WORK_SYSCALL_ENTRY,TI_flags(%ebp)
jnz sysenter_audit
sysenter_do_call:
- cmpl $(NR_syscalls), %eax
+ cmpl $(nr_syscalls), %eax
jae syscall_badsys
call *sys_call_table(,%eax,4)
movl %eax,PT_EAX(%esp)
@@ -454,7 +455,7 @@ sysenter_audit:
movl %ebx,%ecx /* 3rd arg: 1st syscall arg */
movl %eax,%edx /* 2nd arg: syscall number */
movl $AUDIT_ARCH_I386,%eax /* 1st arg: audit arch */
- call __audit_syscall_entry
+ call audit_syscall_entry
pushl_cfi %ebx
movl PT_EAX(%esp),%eax /* reload syscall number */
jmp sysenter_do_call
@@ -465,10 +466,11 @@ sysexit_audit:
TRACE_IRQS_ON
ENABLE_INTERRUPTS(CLBR_ANY)
movl %eax,%edx /* second arg, syscall return value */
- cmpl $-MAX_ERRNO,%eax /* is it an error ? */
- setbe %al /* 1 if so, 0 if not */
+ cmpl $0,%eax /* is it < 0? */
+ setl %al /* 1 if so, 0 if not */
movzbl %al,%eax /* zero-extend that */
- call __audit_syscall_exit
+ inc %eax /* first arg, 0->1(AUDITSC_SUCCESS), 1->2(AUDITSC_FAILURE) */
+ call audit_syscall_exit
DISABLE_INTERRUPTS(CLBR_ANY)
TRACE_IRQS_OFF
movl TI_flags(%ebp), %ecx
@@ -502,7 +504,7 @@ ENTRY(system_call)
# system call tracing in operation / emulation
testl $_TIF_WORK_SYSCALL_ENTRY,TI_flags(%ebp)
jnz syscall_trace_entry
- cmpl $(NR_syscalls), %eax
+ cmpl $(nr_syscalls), %eax
jae syscall_badsys
syscall_call:
call *sys_call_table(,%eax,4)
@@ -652,7 +654,7 @@ syscall_trace_entry:
movl %esp, %eax
call syscall_trace_enter
/* What it returned is what we'll actually use. */
- cmpl $(NR_syscalls), %eax
+ cmpl $(nr_syscalls), %eax
jnae syscall_call
jmp syscall_exit
END(syscall_trace_entry)
@@ -692,28 +694,29 @@ END(syscall_badsys)
* System calls that need a pt_regs pointer.
*/
#define PTREGSCALL0(name) \
-ENTRY(ptregs_##name) ; \
+ ALIGN; \
+ptregs_##name: \
leal 4(%esp),%eax; \
- jmp sys_##name; \
-ENDPROC(ptregs_##name)
+ jmp sys_##name;
#define PTREGSCALL1(name) \
-ENTRY(ptregs_##name) ; \
+ ALIGN; \
+ptregs_##name: \
leal 4(%esp),%edx; \
movl (PT_EBX+4)(%esp),%eax; \
- jmp sys_##name; \
-ENDPROC(ptregs_##name)
+ jmp sys_##name;
#define PTREGSCALL2(name) \
-ENTRY(ptregs_##name) ; \
+ ALIGN; \
+ptregs_##name: \
leal 4(%esp),%ecx; \
movl (PT_ECX+4)(%esp),%edx; \
movl (PT_EBX+4)(%esp),%eax; \
- jmp sys_##name; \
-ENDPROC(ptregs_##name)
+ jmp sys_##name;
#define PTREGSCALL3(name) \
-ENTRY(ptregs_##name) ; \
+ ALIGN; \
+ptregs_##name: \
CFI_STARTPROC; \
leal 4(%esp),%eax; \
pushl_cfi %eax; \
@@ -738,7 +741,8 @@ PTREGSCALL2(vm86)
PTREGSCALL1(vm86old)
/* Clone is an oddball. The 4th arg is in %edi */
-ENTRY(ptregs_clone)
+ ALIGN;
+ptregs_clone:
CFI_STARTPROC
leal 4(%esp),%eax
pushl_cfi %eax
@@ -1209,6 +1213,11 @@ return_to_handler:
jmp *%ecx
#endif
+.section .rodata,"a"
+#include "syscall_table_32.S"
+
+syscall_table_size=(.-sys_call_table)
+
/*
* Some functions should be protected against kprobes
*/
diff --git a/trunk/arch/x86/kernel/entry_64.S b/trunk/arch/x86/kernel/entry_64.S
index 3fe8239fd8fb..940ba711fc28 100644
--- a/trunk/arch/x86/kernel/entry_64.S
+++ b/trunk/arch/x86/kernel/entry_64.S
@@ -55,7 +55,6 @@
#include
#include
#include
-#include
/* Avoid __ASSEMBLER__'ifying just for this. */
#include
@@ -549,7 +548,7 @@ badsys:
#ifdef CONFIG_AUDITSYSCALL
/*
* Fast path for syscall audit without full syscall trace.
- * We just call __audit_syscall_entry() directly, and then
+ * We just call audit_syscall_entry() directly, and then
* jump back to the normal fast path.
*/
auditsys:
@@ -559,21 +558,22 @@ auditsys:
movq %rdi,%rdx /* 3rd arg: 1st syscall arg */
movq %rax,%rsi /* 2nd arg: syscall number */
movl $AUDIT_ARCH_X86_64,%edi /* 1st arg: audit arch */
- call __audit_syscall_entry
+ call audit_syscall_entry
LOAD_ARGS 0 /* reload call-clobbered registers */
jmp system_call_fastpath
/*
- * Return fast path for syscall audit. Call __audit_syscall_exit()
+ * Return fast path for syscall audit. Call audit_syscall_exit()
* directly and then jump back to the fast path with TIF_SYSCALL_AUDIT
* masked off.
*/
sysret_audit:
movq RAX-ARGOFFSET(%rsp),%rsi /* second arg, syscall return value */
- cmpq $-MAX_ERRNO,%rsi /* is it < -MAX_ERRNO? */
- setbe %al /* 1 if so, 0 if not */
+ cmpq $0,%rsi /* is it < 0? */
+ setl %al /* 1 if so, 0 if not */
movzbl %al,%edi /* zero-extend that into %edi */
- call __audit_syscall_exit
+ inc %edi /* first arg, 0->1(AUDITSC_SUCCESS), 1->2(AUDITSC_FAILURE) */
+ call audit_syscall_exit
movl $(_TIF_ALLWORK_MASK & ~_TIF_SYSCALL_AUDIT),%edi
jmp sysret_check
#endif /* CONFIG_AUDITSYSCALL */
diff --git a/trunk/arch/x86/kernel/ptrace.c b/trunk/arch/x86/kernel/ptrace.c
index 50267386b766..89a04c7b5bb6 100644
--- a/trunk/arch/x86/kernel/ptrace.c
+++ b/trunk/arch/x86/kernel/ptrace.c
@@ -1392,18 +1392,20 @@ long syscall_trace_enter(struct pt_regs *regs)
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_enter(regs, regs->orig_ax);
- if (IS_IA32)
- audit_syscall_entry(AUDIT_ARCH_I386,
- regs->orig_ax,
- regs->bx, regs->cx,
- regs->dx, regs->si);
+ if (unlikely(current->audit_context)) {
+ if (IS_IA32)
+ audit_syscall_entry(AUDIT_ARCH_I386,
+ regs->orig_ax,
+ regs->bx, regs->cx,
+ regs->dx, regs->si);
#ifdef CONFIG_X86_64
- else
- audit_syscall_entry(AUDIT_ARCH_X86_64,
- regs->orig_ax,
- regs->di, regs->si,
- regs->dx, regs->r10);
+ else
+ audit_syscall_entry(AUDIT_ARCH_X86_64,
+ regs->orig_ax,
+ regs->di, regs->si,
+ regs->dx, regs->r10);
#endif
+ }
return ret ?: regs->orig_ax;
}
@@ -1412,7 +1414,8 @@ void syscall_trace_leave(struct pt_regs *regs)
{
bool step;
- audit_syscall_exit(regs);
+ if (unlikely(current->audit_context))
+ audit_syscall_exit(AUDITSC_RESULT(regs->ax), regs->ax);
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
trace_sys_exit(regs, regs->ax);
diff --git a/trunk/arch/x86/kernel/syscall_32.c b/trunk/arch/x86/kernel/syscall_32.c
deleted file mode 100644
index 147fcd4941c4..000000000000
--- a/trunk/arch/x86/kernel/syscall_32.c
+++ /dev/null
@@ -1,25 +0,0 @@
-/* System call table for i386. */
-
-#include
-#include
-#include
-#include
-
-#define __SYSCALL_I386(nr, sym, compat) extern asmlinkage void sym(void) ;
-#include
-#undef __SYSCALL_I386
-
-#define __SYSCALL_I386(nr, sym, compat) [nr] = sym,
-
-typedef asmlinkage void (*sys_call_ptr_t)(void);
-
-extern asmlinkage void sys_ni_syscall(void);
-
-const sys_call_ptr_t sys_call_table[__NR_syscall_max+1] = {
- /*
- * Smells like a compiler bug -- it doesn't work
- * when the & below is removed.
- */
- [0 ... __NR_syscall_max] = &sys_ni_syscall,
-#include
-};
diff --git a/trunk/arch/x86/kernel/syscall_64.c b/trunk/arch/x86/kernel/syscall_64.c
index 7ac7943be02c..de87d6008295 100644
--- a/trunk/arch/x86/kernel/syscall_64.c
+++ b/trunk/arch/x86/kernel/syscall_64.c
@@ -5,11 +5,15 @@
#include
#include
-#define __SYSCALL_64(nr, sym, compat) extern asmlinkage void sym(void) ;
-#include
-#undef __SYSCALL_64
+#define __NO_STUBS
-#define __SYSCALL_64(nr, sym, compat) [nr] = sym,
+#define __SYSCALL(nr, sym) extern asmlinkage void sym(void) ;
+#undef _ASM_X86_UNISTD_64_H
+#include
+
+#undef __SYSCALL
+#define __SYSCALL(nr, sym) [nr] = sym,
+#undef _ASM_X86_UNISTD_64_H
typedef void (*sys_call_ptr_t)(void);
@@ -17,9 +21,9 @@ extern void sys_ni_syscall(void);
const sys_call_ptr_t sys_call_table[__NR_syscall_max+1] = {
/*
- * Smells like a compiler bug -- it doesn't work
- * when the & below is removed.
- */
+ *Smells like a like a compiler bug -- it doesn't work
+ *when the & below is removed.
+ */
[0 ... __NR_syscall_max] = &sys_ni_syscall,
-#include
+#include
};
diff --git a/trunk/arch/x86/kernel/syscall_table_32.S b/trunk/arch/x86/kernel/syscall_table_32.S
new file mode 100644
index 000000000000..9a0e31293920
--- /dev/null
+++ b/trunk/arch/x86/kernel/syscall_table_32.S
@@ -0,0 +1,350 @@
+ENTRY(sys_call_table)
+ .long sys_restart_syscall /* 0 - old "setup()" system call, used for restarting */
+ .long sys_exit
+ .long ptregs_fork
+ .long sys_read
+ .long sys_write
+ .long sys_open /* 5 */
+ .long sys_close
+ .long sys_waitpid
+ .long sys_creat
+ .long sys_link
+ .long sys_unlink /* 10 */
+ .long ptregs_execve
+ .long sys_chdir
+ .long sys_time
+ .long sys_mknod
+ .long sys_chmod /* 15 */
+ .long sys_lchown16
+ .long sys_ni_syscall /* old break syscall holder */
+ .long sys_stat
+ .long sys_lseek
+ .long sys_getpid /* 20 */
+ .long sys_mount
+ .long sys_oldumount
+ .long sys_setuid16
+ .long sys_getuid16
+ .long sys_stime /* 25 */
+ .long sys_ptrace
+ .long sys_alarm
+ .long sys_fstat
+ .long sys_pause
+ .long sys_utime /* 30 */
+ .long sys_ni_syscall /* old stty syscall holder */
+ .long sys_ni_syscall /* old gtty syscall holder */
+ .long sys_access
+ .long sys_nice
+ .long sys_ni_syscall /* 35 - old ftime syscall holder */
+ .long sys_sync
+ .long sys_kill
+ .long sys_rename
+ .long sys_mkdir
+ .long sys_rmdir /* 40 */
+ .long sys_dup
+ .long sys_pipe
+ .long sys_times
+ .long sys_ni_syscall /* old prof syscall holder */
+ .long sys_brk /* 45 */
+ .long sys_setgid16
+ .long sys_getgid16
+ .long sys_signal
+ .long sys_geteuid16
+ .long sys_getegid16 /* 50 */
+ .long sys_acct
+ .long sys_umount /* recycled never used phys() */
+ .long sys_ni_syscall /* old lock syscall holder */
+ .long sys_ioctl
+ .long sys_fcntl /* 55 */
+ .long sys_ni_syscall /* old mpx syscall holder */
+ .long sys_setpgid
+ .long sys_ni_syscall /* old ulimit syscall holder */
+ .long sys_olduname
+ .long sys_umask /* 60 */
+ .long sys_chroot
+ .long sys_ustat
+ .long sys_dup2
+ .long sys_getppid
+ .long sys_getpgrp /* 65 */
+ .long sys_setsid
+ .long sys_sigaction
+ .long sys_sgetmask
+ .long sys_ssetmask
+ .long sys_setreuid16 /* 70 */
+ .long sys_setregid16
+ .long sys_sigsuspend
+ .long sys_sigpending
+ .long sys_sethostname
+ .long sys_setrlimit /* 75 */
+ .long sys_old_getrlimit
+ .long sys_getrusage
+ .long sys_gettimeofday
+ .long sys_settimeofday
+ .long sys_getgroups16 /* 80 */
+ .long sys_setgroups16
+ .long sys_old_select
+ .long sys_symlink
+ .long sys_lstat
+ .long sys_readlink /* 85 */
+ .long sys_uselib
+ .long sys_swapon
+ .long sys_reboot
+ .long sys_old_readdir
+ .long sys_old_mmap /* 90 */
+ .long sys_munmap
+ .long sys_truncate
+ .long sys_ftruncate
+ .long sys_fchmod
+ .long sys_fchown16 /* 95 */
+ .long sys_getpriority
+ .long sys_setpriority
+ .long sys_ni_syscall /* old profil syscall holder */
+ .long sys_statfs
+ .long sys_fstatfs /* 100 */
+ .long sys_ioperm
+ .long sys_socketcall
+ .long sys_syslog
+ .long sys_setitimer
+ .long sys_getitimer /* 105 */
+ .long sys_newstat
+ .long sys_newlstat
+ .long sys_newfstat
+ .long sys_uname
+ .long ptregs_iopl /* 110 */
+ .long sys_vhangup
+ .long sys_ni_syscall /* old "idle" system call */
+ .long ptregs_vm86old
+ .long sys_wait4
+ .long sys_swapoff /* 115 */
+ .long sys_sysinfo
+ .long sys_ipc
+ .long sys_fsync
+ .long ptregs_sigreturn
+ .long ptregs_clone /* 120 */
+ .long sys_setdomainname
+ .long sys_newuname
+ .long sys_modify_ldt
+ .long sys_adjtimex
+ .long sys_mprotect /* 125 */
+ .long sys_sigprocmask
+ .long sys_ni_syscall /* old "create_module" */
+ .long sys_init_module
+ .long sys_delete_module
+ .long sys_ni_syscall /* 130: old "get_kernel_syms" */
+ .long sys_quotactl
+ .long sys_getpgid
+ .long sys_fchdir
+ .long sys_bdflush
+ .long sys_sysfs /* 135 */
+ .long sys_personality
+ .long sys_ni_syscall /* reserved for afs_syscall */
+ .long sys_setfsuid16
+ .long sys_setfsgid16
+ .long sys_llseek /* 140 */
+ .long sys_getdents
+ .long sys_select
+ .long sys_flock
+ .long sys_msync
+ .long sys_readv /* 145 */
+ .long sys_writev
+ .long sys_getsid
+ .long sys_fdatasync
+ .long sys_sysctl
+ .long sys_mlock /* 150 */
+ .long sys_munlock
+ .long sys_mlockall
+ .long sys_munlockall
+ .long sys_sched_setparam
+ .long sys_sched_getparam /* 155 */
+ .long sys_sched_setscheduler
+ .long sys_sched_getscheduler
+ .long sys_sched_yield
+ .long sys_sched_get_priority_max
+ .long sys_sched_get_priority_min /* 160 */
+ .long sys_sched_rr_get_interval
+ .long sys_nanosleep
+ .long sys_mremap
+ .long sys_setresuid16
+ .long sys_getresuid16 /* 165 */
+ .long ptregs_vm86
+ .long sys_ni_syscall /* Old sys_query_module */
+ .long sys_poll
+ .long sys_ni_syscall /* Old nfsservctl */
+ .long sys_setresgid16 /* 170 */
+ .long sys_getresgid16
+ .long sys_prctl
+ .long ptregs_rt_sigreturn
+ .long sys_rt_sigaction
+ .long sys_rt_sigprocmask /* 175 */
+ .long sys_rt_sigpending
+ .long sys_rt_sigtimedwait
+ .long sys_rt_sigqueueinfo
+ .long sys_rt_sigsuspend
+ .long sys_pread64 /* 180 */
+ .long sys_pwrite64
+ .long sys_chown16
+ .long sys_getcwd
+ .long sys_capget
+ .long sys_capset /* 185 */
+ .long ptregs_sigaltstack
+ .long sys_sendfile
+ .long sys_ni_syscall /* reserved for streams1 */
+ .long sys_ni_syscall /* reserved for streams2 */
+ .long ptregs_vfork /* 190 */
+ .long sys_getrlimit
+ .long sys_mmap_pgoff
+ .long sys_truncate64
+ .long sys_ftruncate64
+ .long sys_stat64 /* 195 */
+ .long sys_lstat64
+ .long sys_fstat64
+ .long sys_lchown
+ .long sys_getuid
+ .long sys_getgid /* 200 */
+ .long sys_geteuid
+ .long sys_getegid
+ .long sys_setreuid
+ .long sys_setregid
+ .long sys_getgroups /* 205 */
+ .long sys_setgroups
+ .long sys_fchown
+ .long sys_setresuid
+ .long sys_getresuid
+ .long sys_setresgid /* 210 */
+ .long sys_getresgid
+ .long sys_chown
+ .long sys_setuid
+ .long sys_setgid
+ .long sys_setfsuid /* 215 */
+ .long sys_setfsgid
+ .long sys_pivot_root
+ .long sys_mincore
+ .long sys_madvise
+ .long sys_getdents64 /* 220 */
+ .long sys_fcntl64
+ .long sys_ni_syscall /* reserved for TUX */
+ .long sys_ni_syscall
+ .long sys_gettid
+ .long sys_readahead /* 225 */
+ .long sys_setxattr
+ .long sys_lsetxattr
+ .long sys_fsetxattr
+ .long sys_getxattr
+ .long sys_lgetxattr /* 230 */
+ .long sys_fgetxattr
+ .long sys_listxattr
+ .long sys_llistxattr
+ .long sys_flistxattr
+ .long sys_removexattr /* 235 */
+ .long sys_lremovexattr
+ .long sys_fremovexattr
+ .long sys_tkill
+ .long sys_sendfile64
+ .long sys_futex /* 240 */
+ .long sys_sched_setaffinity
+ .long sys_sched_getaffinity
+ .long sys_set_thread_area
+ .long sys_get_thread_area
+ .long sys_io_setup /* 245 */
+ .long sys_io_destroy
+ .long sys_io_getevents
+ .long sys_io_submit
+ .long sys_io_cancel
+ .long sys_fadvise64 /* 250 */
+ .long sys_ni_syscall
+ .long sys_exit_group
+ .long sys_lookup_dcookie
+ .long sys_epoll_create
+ .long sys_epoll_ctl /* 255 */
+ .long sys_epoll_wait
+ .long sys_remap_file_pages
+ .long sys_set_tid_address
+ .long sys_timer_create
+ .long sys_timer_settime /* 260 */
+ .long sys_timer_gettime
+ .long sys_timer_getoverrun
+ .long sys_timer_delete
+ .long sys_clock_settime
+ .long sys_clock_gettime /* 265 */
+ .long sys_clock_getres
+ .long sys_clock_nanosleep
+ .long sys_statfs64
+ .long sys_fstatfs64
+ .long sys_tgkill /* 270 */
+ .long sys_utimes
+ .long sys_fadvise64_64
+ .long sys_ni_syscall /* sys_vserver */
+ .long sys_mbind
+ .long sys_get_mempolicy
+ .long sys_set_mempolicy
+ .long sys_mq_open
+ .long sys_mq_unlink
+ .long sys_mq_timedsend
+ .long sys_mq_timedreceive /* 280 */
+ .long sys_mq_notify
+ .long sys_mq_getsetattr
+ .long sys_kexec_load
+ .long sys_waitid
+ .long sys_ni_syscall /* 285 */ /* available */
+ .long sys_add_key
+ .long sys_request_key
+ .long sys_keyctl
+ .long sys_ioprio_set
+ .long sys_ioprio_get /* 290 */
+ .long sys_inotify_init
+ .long sys_inotify_add_watch
+ .long sys_inotify_rm_watch
+ .long sys_migrate_pages
+ .long sys_openat /* 295 */
+ .long sys_mkdirat
+ .long sys_mknodat
+ .long sys_fchownat
+ .long sys_futimesat
+ .long sys_fstatat64 /* 300 */
+ .long sys_unlinkat
+ .long sys_renameat
+ .long sys_linkat
+ .long sys_symlinkat
+ .long sys_readlinkat /* 305 */
+ .long sys_fchmodat
+ .long sys_faccessat
+ .long sys_pselect6
+ .long sys_ppoll
+ .long sys_unshare /* 310 */
+ .long sys_set_robust_list
+ .long sys_get_robust_list
+ .long sys_splice
+ .long sys_sync_file_range
+ .long sys_tee /* 315 */
+ .long sys_vmsplice
+ .long sys_move_pages
+ .long sys_getcpu
+ .long sys_epoll_pwait
+ .long sys_utimensat /* 320 */
+ .long sys_signalfd
+ .long sys_timerfd_create
+ .long sys_eventfd
+ .long sys_fallocate
+ .long sys_timerfd_settime /* 325 */
+ .long sys_timerfd_gettime
+ .long sys_signalfd4
+ .long sys_eventfd2
+ .long sys_epoll_create1
+ .long sys_dup3 /* 330 */
+ .long sys_pipe2
+ .long sys_inotify_init1
+ .long sys_preadv
+ .long sys_pwritev
+ .long sys_rt_tgsigqueueinfo /* 335 */
+ .long sys_perf_event_open
+ .long sys_recvmmsg
+ .long sys_fanotify_init
+ .long sys_fanotify_mark
+ .long sys_prlimit64 /* 340 */
+ .long sys_name_to_handle_at
+ .long sys_open_by_handle_at
+ .long sys_clock_adjtime
+ .long sys_syncfs
+ .long sys_sendmmsg /* 345 */
+ .long sys_setns
+ .long sys_process_vm_readv
+ .long sys_process_vm_writev
diff --git a/trunk/arch/x86/kernel/vm86_32.c b/trunk/arch/x86/kernel/vm86_32.c
index b466cab5ba15..863f8753ab0a 100644
--- a/trunk/arch/x86/kernel/vm86_32.c
+++ b/trunk/arch/x86/kernel/vm86_32.c
@@ -335,11 +335,9 @@ static void do_sys_vm86(struct kernel_vm86_struct *info, struct task_struct *tsk
if (info->flags & VM86_SCREEN_BITMAP)
mark_screen_rdonly(tsk->mm);
- /*call __audit_syscall_exit since we do not exit via the normal paths */
-#ifdef CONFIG_AUDITSYSCALL
+ /*call audit_syscall_exit since we do not exit via the normal paths */
if (unlikely(current->audit_context))
- __audit_syscall_exit(1, 0);
-#endif
+ audit_syscall_exit(AUDITSC_RESULT(0), 0);
__asm__ __volatile__(
"movl %0,%%esp\n\t"
diff --git a/trunk/arch/x86/mm/srat.c b/trunk/arch/x86/mm/srat.c
index 1c1c4f46a7c1..fd61b3fb7341 100644
--- a/trunk/arch/x86/mm/srat.c
+++ b/trunk/arch/x86/mm/srat.c
@@ -109,8 +109,6 @@ acpi_numa_processor_affinity_init(struct acpi_srat_cpu_affinity *pa)
if ((pa->flags & ACPI_SRAT_CPU_ENABLED) == 0)
return;
pxm = pa->proximity_domain_lo;
- if (acpi_srat_revision >= 2)
- pxm |= *((unsigned int*)pa->proximity_domain_hi) << 8;
node = setup_node(pxm);
if (node < 0) {
printk(KERN_ERR "SRAT: Too many proximity domains %x\n", pxm);
@@ -162,8 +160,6 @@ acpi_numa_memory_affinity_init(struct acpi_srat_mem_affinity *ma)
start = ma->base_address;
end = start + ma->length;
pxm = ma->proximity_domain;
- if (acpi_srat_revision <= 1)
- pxm &= 0xff;
node = setup_node(pxm);
if (node < 0) {
printk(KERN_ERR "SRAT: Too many proximity domains.\n");
diff --git a/trunk/arch/x86/syscalls/Makefile b/trunk/arch/x86/syscalls/Makefile
deleted file mode 100644
index 564b2476fede..000000000000
--- a/trunk/arch/x86/syscalls/Makefile
+++ /dev/null
@@ -1,43 +0,0 @@
-out := $(obj)/../include/generated/asm
-
-# Create output directory if not already present
-_dummy := $(shell [ -d '$(out)' ] || mkdir -p '$(out)')
-
-syscall32 := $(srctree)/$(src)/syscall_32.tbl
-syscall64 := $(srctree)/$(src)/syscall_64.tbl
-
-syshdr := $(srctree)/$(src)/syscallhdr.sh
-systbl := $(srctree)/$(src)/syscalltbl.sh
-
-quiet_cmd_syshdr = SYSHDR $@
- cmd_syshdr = $(CONFIG_SHELL) '$(syshdr)' $< $@ \
- $(syshdr_abi_$(basetarget)) $(syshdr_pfx_$(basetarget))
-quiet_cmd_systbl = SYSTBL $@
- cmd_systbl = $(CONFIG_SHELL) '$(systbl)' $< $@
-
-syshdr_abi_unistd_32 := i386
-$(out)/unistd_32.h: $(syscall32) $(syshdr)
- $(call if_changed,syshdr)
-
-syshdr_abi_unistd_32_ia32 := i386
-syshdr_pfx_unistd_32_ia32 := ia32_
-$(out)/unistd_32_ia32.h: $(syscall32) $(syshdr)
- $(call if_changed,syshdr)
-
-syshdr_abi_unistd_64 := 64
-$(out)/unistd_64.h: $(syscall64) $(syshdr)
- $(call if_changed,syshdr)
-
-$(out)/syscalls_32.h: $(syscall32) $(systbl)
- $(call if_changed,systbl)
-$(out)/syscalls_64.h: $(syscall64) $(systbl)
- $(call if_changed,systbl)
-
-syshdr-y += unistd_32.h unistd_64.h
-syshdr-y += syscalls_32.h
-syshdr-$(CONFIG_X86_64) += unistd_32_ia32.h
-syshdr-$(CONFIG_X86_64) += syscalls_64.h
-
-targets += $(syshdr-y)
-
-all: $(addprefix $(out)/,$(targets))
diff --git a/trunk/arch/x86/syscalls/syscall_32.tbl b/trunk/arch/x86/syscalls/syscall_32.tbl
deleted file mode 100644
index ce98e287c066..000000000000
--- a/trunk/arch/x86/syscalls/syscall_32.tbl
+++ /dev/null
@@ -1,357 +0,0 @@
-#
-# 32-bit system call numbers and entry vectors
-#
-# The format is:
-#
-#
-# The abi is always "i386" for this file.
-#
-0 i386 restart_syscall sys_restart_syscall
-1 i386 exit sys_exit
-2 i386 fork ptregs_fork stub32_fork
-3 i386 read sys_read
-4 i386 write sys_write
-5 i386 open sys_open compat_sys_open
-6 i386 close sys_close
-7 i386 waitpid sys_waitpid sys32_waitpid
-8 i386 creat sys_creat
-9 i386 link sys_link
-10 i386 unlink sys_unlink
-11 i386 execve ptregs_execve stub32_execve
-12 i386 chdir sys_chdir
-13 i386 time sys_time compat_sys_time
-14 i386 mknod sys_mknod
-15 i386 chmod sys_chmod
-16 i386 lchown sys_lchown16
-17 i386 break
-18 i386 oldstat sys_stat
-19 i386 lseek sys_lseek sys32_lseek
-20 i386 getpid sys_getpid
-21 i386 mount sys_mount compat_sys_mount
-22 i386 umount sys_oldumount
-23 i386 setuid sys_setuid16
-24 i386 getuid sys_getuid16
-25 i386 stime sys_stime compat_sys_stime
-26 i386 ptrace sys_ptrace compat_sys_ptrace
-27 i386 alarm sys_alarm
-28 i386 oldfstat sys_fstat
-29 i386 pause sys_pause
-30 i386 utime sys_utime compat_sys_utime
-31 i386 stty
-32 i386 gtty
-33 i386 access sys_access
-34 i386 nice sys_nice
-35 i386 ftime
-36 i386 sync sys_sync
-37 i386 kill sys_kill sys32_kill
-38 i386 rename sys_rename
-39 i386 mkdir sys_mkdir
-40 i386 rmdir sys_rmdir
-41 i386 dup sys_dup
-42 i386 pipe sys_pipe
-43 i386 times sys_times compat_sys_times
-44 i386 prof
-45 i386 brk sys_brk
-46 i386 setgid sys_setgid16
-47 i386 getgid sys_getgid16
-48 i386 signal sys_signal
-49 i386 geteuid sys_geteuid16
-50 i386 getegid sys_getegid16
-51 i386 acct sys_acct
-52 i386 umount2 sys_umount
-53 i386 lock
-54 i386 ioctl sys_ioctl compat_sys_ioctl
-55 i386 fcntl sys_fcntl compat_sys_fcntl64
-56 i386 mpx
-57 i386 setpgid sys_setpgid
-58 i386 ulimit
-59 i386 oldolduname sys_olduname
-60 i386 umask sys_umask
-61 i386 chroot sys_chroot
-62 i386 ustat sys_ustat compat_sys_ustat
-63 i386 dup2 sys_dup2
-64 i386 getppid sys_getppid
-65 i386 getpgrp sys_getpgrp
-66 i386 setsid sys_setsid
-67 i386 sigaction sys_sigaction sys32_sigaction
-68 i386 sgetmask sys_sgetmask
-69 i386 ssetmask sys_ssetmask
-70 i386 setreuid sys_setreuid16
-71 i386 setregid sys_setregid16
-72 i386 sigsuspend sys_sigsuspend sys32_sigsuspend
-73 i386 sigpending sys_sigpending compat_sys_sigpending
-74 i386 sethostname sys_sethostname
-75 i386 setrlimit sys_setrlimit compat_sys_setrlimit
-76 i386 getrlimit sys_old_getrlimit compat_sys_old_getrlimit
-77 i386 getrusage sys_getrusage compat_sys_getrusage
-78 i386 gettimeofday sys_gettimeofday compat_sys_gettimeofday
-79 i386 settimeofday sys_settimeofday compat_sys_settimeofday
-80 i386 getgroups sys_getgroups16
-81 i386 setgroups sys_setgroups16
-82 i386 select sys_old_select compat_sys_old_select
-83 i386 symlink sys_symlink
-84 i386 oldlstat sys_lstat
-85 i386 readlink sys_readlink
-86 i386 uselib sys_uselib
-87 i386 swapon sys_swapon
-88 i386 reboot sys_reboot
-89 i386 readdir sys_old_readdir compat_sys_old_readdir
-90 i386 mmap sys_old_mmap sys32_mmap
-91 i386 munmap sys_munmap
-92 i386 truncate sys_truncate
-93 i386 ftruncate sys_ftruncate
-94 i386 fchmod sys_fchmod
-95 i386 fchown sys_fchown16
-96 i386 getpriority sys_getpriority
-97 i386 setpriority sys_setpriority
-98 i386 profil
-99 i386 statfs sys_statfs compat_sys_statfs
-100 i386 fstatfs sys_fstatfs compat_sys_fstatfs
-101 i386 ioperm sys_ioperm
-102 i386 socketcall sys_socketcall compat_sys_socketcall
-103 i386 syslog sys_syslog
-104 i386 setitimer sys_setitimer compat_sys_setitimer
-105 i386 getitimer sys_getitimer compat_sys_getitimer
-106 i386 stat sys_newstat compat_sys_newstat
-107 i386 lstat sys_newlstat compat_sys_newlstat
-108 i386 fstat sys_newfstat compat_sys_newfstat
-109 i386 olduname sys_uname
-110 i386 iopl ptregs_iopl stub32_iopl
-111 i386 vhangup sys_vhangup
-112 i386 idle
-113 i386 vm86old ptregs_vm86old sys32_vm86_warning
-114 i386 wait4 sys_wait4 compat_sys_wait4
-115 i386 swapoff sys_swapoff
-116 i386 sysinfo sys_sysinfo compat_sys_sysinfo
-117 i386 ipc sys_ipc sys32_ipc
-118 i386 fsync sys_fsync
-119 i386 sigreturn ptregs_sigreturn stub32_sigreturn
-120 i386 clone ptregs_clone stub32_clone
-121 i386 setdomainname sys_setdomainname
-122 i386 uname sys_newuname
-123 i386 modify_ldt sys_modify_ldt
-124 i386 adjtimex sys_adjtimex compat_sys_adjtimex
-125 i386 mprotect sys_mprotect sys32_mprotect
-126 i386 sigprocmask sys_sigprocmask compat_sys_sigprocmask
-127 i386 create_module
-128 i386 init_module sys_init_module
-129 i386 delete_module sys_delete_module
-130 i386 get_kernel_syms
-131 i386 quotactl sys_quotactl sys32_quotactl
-132 i386 getpgid sys_getpgid
-133 i386 fchdir sys_fchdir
-134 i386 bdflush sys_bdflush
-135 i386 sysfs sys_sysfs
-136 i386 personality sys_personality
-137 i386 afs_syscall
-138 i386 setfsuid sys_setfsuid16
-139 i386 setfsgid sys_setfsgid16
-140 i386 _llseek sys_llseek
-141 i386 getdents sys_getdents compat_sys_getdents
-142 i386 _newselect sys_select compat_sys_select
-143 i386 flock sys_flock
-144 i386 msync sys_msync
-145 i386 readv sys_readv compat_sys_readv
-146 i386 writev sys_writev compat_sys_writev
-147 i386 getsid sys_getsid
-148 i386 fdatasync sys_fdatasync
-149 i386 _sysctl sys_sysctl compat_sys_sysctl
-150 i386 mlock sys_mlock
-151 i386 munlock sys_munlock
-152 i386 mlockall sys_mlockall
-153 i386 munlockall sys_munlockall
-154 i386 sched_setparam sys_sched_setparam
-155 i386 sched_getparam sys_sched_getparam
-156 i386 sched_setscheduler sys_sched_setscheduler
-157 i386 sched_getscheduler sys_sched_getscheduler
-158 i386 sched_yield sys_sched_yield
-159 i386 sched_get_priority_max sys_sched_get_priority_max
-160 i386 sched_get_priority_min sys_sched_get_priority_min
-161 i386 sched_rr_get_interval sys_sched_rr_get_interval sys32_sched_rr_get_interval
-162 i386 nanosleep sys_nanosleep compat_sys_nanosleep
-163 i386 mremap sys_mremap
-164 i386 setresuid sys_setresuid16
-165 i386 getresuid sys_getresuid16
-166 i386 vm86 ptregs_vm86 sys32_vm86_warning
-167 i386 query_module
-168 i386 poll sys_poll
-169 i386 nfsservctl
-170 i386 setresgid sys_setresgid16
-171 i386 getresgid sys_getresgid16
-172 i386 prctl sys_prctl
-173 i386 rt_sigreturn ptregs_rt_sigreturn stub32_rt_sigreturn
-174 i386 rt_sigaction sys_rt_sigaction sys32_rt_sigaction
-175 i386 rt_sigprocmask sys_rt_sigprocmask sys32_rt_sigprocmask
-176 i386 rt_sigpending sys_rt_sigpending sys32_rt_sigpending
-177 i386 rt_sigtimedwait sys_rt_sigtimedwait compat_sys_rt_sigtimedwait
-178 i386 rt_sigqueueinfo sys_rt_sigqueueinfo sys32_rt_sigqueueinfo
-179 i386 rt_sigsuspend sys_rt_sigsuspend
-180 i386 pread64 sys_pread64 sys32_pread
-181 i386 pwrite64 sys_pwrite64 sys32_pwrite
-182 i386 chown sys_chown16
-183 i386 getcwd sys_getcwd
-184 i386 capget sys_capget
-185 i386 capset sys_capset
-186 i386 sigaltstack ptregs_sigaltstack stub32_sigaltstack
-187 i386 sendfile sys_sendfile sys32_sendfile
-188 i386 getpmsg
-189 i386 putpmsg
-190 i386 vfork ptregs_vfork stub32_vfork
-191 i386 ugetrlimit sys_getrlimit compat_sys_getrlimit
-192 i386 mmap2 sys_mmap_pgoff
-193 i386 truncate64 sys_truncate64 sys32_truncate64
-194 i386 ftruncate64 sys_ftruncate64 sys32_ftruncate64
-195 i386 stat64 sys_stat64 sys32_stat64
-196 i386 lstat64 sys_lstat64 sys32_lstat64
-197 i386 fstat64 sys_fstat64 sys32_fstat64
-198 i386 lchown32 sys_lchown
-199 i386 getuid32 sys_getuid
-200 i386 getgid32 sys_getgid
-201 i386 geteuid32 sys_geteuid
-202 i386 getegid32 sys_getegid
-203 i386 setreuid32 sys_setreuid
-204 i386 setregid32 sys_setregid
-205 i386 getgroups32 sys_getgroups
-206 i386 setgroups32 sys_setgroups
-207 i386 fchown32 sys_fchown
-208 i386 setresuid32 sys_setresuid
-209 i386 getresuid32 sys_getresuid
-210 i386 setresgid32 sys_setresgid
-211 i386 getresgid32 sys_getresgid
-212 i386 chown32 sys_chown
-213 i386 setuid32 sys_setuid
-214 i386 setgid32 sys_setgid
-215 i386 setfsuid32 sys_setfsuid
-216 i386 setfsgid32 sys_setfsgid
-217 i386 pivot_root sys_pivot_root
-218 i386 mincore sys_mincore
-219 i386 madvise sys_madvise
-220 i386 getdents64 sys_getdents64 compat_sys_getdents64
-221 i386 fcntl64 sys_fcntl64 compat_sys_fcntl64
-# 222 is unused
-# 223 is unused
-224 i386 gettid sys_gettid
-225 i386 readahead sys_readahead sys32_readahead
-226 i386 setxattr sys_setxattr
-227 i386 lsetxattr sys_lsetxattr
-228 i386 fsetxattr sys_fsetxattr
-229 i386 getxattr sys_getxattr
-230 i386 lgetxattr sys_lgetxattr
-231 i386 fgetxattr sys_fgetxattr
-232 i386 listxattr sys_listxattr
-233 i386 llistxattr sys_llistxattr
-234 i386 flistxattr sys_flistxattr
-235 i386 removexattr sys_removexattr
-236 i386 lremovexattr sys_lremovexattr
-237 i386 fremovexattr sys_fremovexattr
-238 i386 tkill sys_tkill
-239 i386 sendfile64 sys_sendfile64
-240 i386 futex sys_futex compat_sys_futex
-241 i386 sched_setaffinity sys_sched_setaffinity compat_sys_sched_setaffinity
-242 i386 sched_getaffinity sys_sched_getaffinity compat_sys_sched_getaffinity
-243 i386 set_thread_area sys_set_thread_area
-244 i386 get_thread_area sys_get_thread_area
-245 i386 io_setup sys_io_setup compat_sys_io_setup
-246 i386 io_destroy sys_io_destroy
-247 i386 io_getevents sys_io_getevents compat_sys_io_getevents
-248 i386 io_submit sys_io_submit compat_sys_io_submit
-249 i386 io_cancel sys_io_cancel
-250 i386 fadvise64 sys_fadvise64 sys32_fadvise64
-# 251 is available for reuse (was briefly sys_set_zone_reclaim)
-252 i386 exit_group sys_exit_group
-253 i386 lookup_dcookie sys_lookup_dcookie sys32_lookup_dcookie
-254 i386 epoll_create sys_epoll_create
-255 i386 epoll_ctl sys_epoll_ctl
-256 i386 epoll_wait sys_epoll_wait
-257 i386 remap_file_pages sys_remap_file_pages
-258 i386 set_tid_address sys_set_tid_address
-259 i386 timer_create sys_timer_create compat_sys_timer_create
-260 i386 timer_settime sys_timer_settime compat_sys_timer_settime
-261 i386 timer_gettime sys_timer_gettime compat_sys_timer_gettime
-262 i386 timer_getoverrun sys_timer_getoverrun
-263 i386 timer_delete sys_timer_delete
-264 i386 clock_settime sys_clock_settime compat_sys_clock_settime
-265 i386 clock_gettime sys_clock_gettime compat_sys_clock_gettime
-266 i386 clock_getres sys_clock_getres compat_sys_clock_getres
-267 i386 clock_nanosleep sys_clock_nanosleep compat_sys_clock_nanosleep
-268 i386 statfs64 sys_statfs64 compat_sys_statfs64
-269 i386 fstatfs64 sys_fstatfs64 compat_sys_fstatfs64
-270 i386 tgkill sys_tgkill
-271 i386 utimes sys_utimes compat_sys_utimes
-272 i386 fadvise64_64 sys_fadvise64_64 sys32_fadvise64_64
-273 i386 vserver
-274 i386 mbind sys_mbind
-275 i386 get_mempolicy sys_get_mempolicy compat_sys_get_mempolicy
-276 i386 set_mempolicy sys_set_mempolicy
-277 i386 mq_open sys_mq_open compat_sys_mq_open
-278 i386 mq_unlink sys_mq_unlink
-279 i386 mq_timedsend sys_mq_timedsend compat_sys_mq_timedsend
-280 i386 mq_timedreceive sys_mq_timedreceive compat_sys_mq_timedreceive
-281 i386 mq_notify sys_mq_notify compat_sys_mq_notify
-282 i386 mq_getsetaddr sys_mq_getsetattr compat_sys_mq_getsetattr
-283 i386 kexec_load sys_kexec_load compat_sys_kexec_load
-284 i386 waitid sys_waitid compat_sys_waitid
-# 285 sys_setaltroot
-286 i386 add_key sys_add_key
-287 i386 request_key sys_request_key
-288 i386 keyctl sys_keyctl
-289 i386 ioprio_set sys_ioprio_set
-290 i386 ioprio_get sys_ioprio_get
-291 i386 inotify_init sys_inotify_init
-292 i386 inotify_add_watch sys_inotify_add_watch
-293 i386 inotify_rm_watch sys_inotify_rm_watch
-294 i386 migrate_pages sys_migrate_pages
-295 i386 openat sys_openat compat_sys_openat
-296 i386 mkdirat sys_mkdirat
-297 i386 mknodat sys_mknodat
-298 i386 fchownat sys_fchownat
-299 i386 futimesat sys_futimesat compat_sys_futimesat
-300 i386 fstatat64 sys_fstatat64 sys32_fstatat
-301 i386 unlinkat sys_unlinkat
-302 i386 renameat sys_renameat
-303 i386 linkat sys_linkat
-304 i386 symlinkat sys_symlinkat
-305 i386 readlinkat sys_readlinkat
-306 i386 fchmodat sys_fchmodat
-307 i386 faccessat sys_faccessat
-308 i386 pselect6 sys_pselect6 compat_sys_pselect6
-309 i386 ppoll sys_ppoll compat_sys_ppoll
-310 i386 unshare sys_unshare
-311 i386 set_robust_list sys_set_robust_list compat_sys_set_robust_list
-312 i386 get_robust_list sys_get_robust_list compat_sys_get_robust_list
-313 i386 splice sys_splice
-314 i386 sync_file_range sys_sync_file_range sys32_sync_file_range
-315 i386 tee sys_tee
-316 i386 vmsplice sys_vmsplice compat_sys_vmsplice
-317 i386 move_pages sys_move_pages compat_sys_move_pages
-318 i386 getcpu sys_getcpu
-319 i386 epoll_pwait sys_epoll_pwait
-320 i386 utimensat sys_utimensat compat_sys_utimensat
-321 i386 signalfd sys_signalfd compat_sys_signalfd
-322 i386 timerfd_create sys_timerfd_create
-323 i386 eventfd sys_eventfd
-324 i386 fallocate sys_fallocate sys32_fallocate
-325 i386 timerfd_settime sys_timerfd_settime compat_sys_timerfd_settime
-326 i386 timerfd_gettime sys_timerfd_gettime compat_sys_timerfd_gettime
-327 i386 signalfd4 sys_signalfd4 compat_sys_signalfd4
-328 i386 eventfd2 sys_eventfd2
-329 i386 epoll_create1 sys_epoll_create1
-330 i386 dup3 sys_dup3
-331 i386 pipe2 sys_pipe2
-332 i386 inotify_init1 sys_inotify_init1
-333 i386 preadv sys_preadv compat_sys_preadv
-334 i386 pwritev sys_pwritev compat_sys_pwritev
-335 i386 rt_tgsigqueueinfo sys_rt_tgsigqueueinfo compat_sys_rt_tgsigqueueinfo
-336 i386 perf_event_open sys_perf_event_open
-337 i386 recvmmsg sys_recvmmsg compat_sys_recvmmsg
-338 i386 fanotify_init sys_fanotify_init
-339 i386 fanotify_mark sys_fanotify_mark sys32_fanotify_mark
-340 i386 prlimit64 sys_prlimit64
-341 i386 name_to_handle_at sys_name_to_handle_at
-342 i386 open_by_handle_at sys_open_by_handle_at compat_sys_open_by_handle_at
-343 i386 clock_adjtime sys_clock_adjtime compat_sys_clock_adjtime
-344 i386 syncfs sys_syncfs
-345 i386 sendmmsg sys_sendmmsg compat_sys_sendmmsg
-346 i386 setns sys_setns
-347 i386 process_vm_readv sys_process_vm_readv compat_sys_process_vm_readv
-348 i386 process_vm_writev sys_process_vm_writev compat_sys_process_vm_writev
diff --git a/trunk/arch/x86/syscalls/syscall_64.tbl b/trunk/arch/x86/syscalls/syscall_64.tbl
deleted file mode 100644
index b440a8f7eefa..000000000000
--- a/trunk/arch/x86/syscalls/syscall_64.tbl
+++ /dev/null
@@ -1,320 +0,0 @@
-#
-# 64-bit system call numbers and entry vectors
-#
-# The format is:
-#
-#
-# The abi is always "64" for this file (for now.)
-#
-0 64 read sys_read
-1 64 write sys_write
-2 64 open sys_open
-3 64 close sys_close
-4 64 stat sys_newstat
-5 64 fstat sys_newfstat
-6 64 lstat sys_newlstat
-7 64 poll sys_poll
-8 64 lseek sys_lseek
-9 64 mmap sys_mmap
-10 64 mprotect sys_mprotect
-11 64 munmap sys_munmap
-12 64 brk sys_brk
-13 64 rt_sigaction sys_rt_sigaction
-14 64 rt_sigprocmask sys_rt_sigprocmask
-15 64 rt_sigreturn stub_rt_sigreturn
-16 64 ioctl sys_ioctl
-17 64 pread64 sys_pread64
-18 64 pwrite64 sys_pwrite64
-19 64 readv sys_readv
-20 64 writev sys_writev
-21 64 access sys_access
-22 64 pipe sys_pipe
-23 64 select sys_select
-24 64 sched_yield sys_sched_yield
-25 64 mremap sys_mremap
-26 64 msync sys_msync
-27 64 mincore sys_mincore
-28 64 madvise sys_madvise
-29 64 shmget sys_shmget
-30 64 shmat sys_shmat
-31 64 shmctl sys_shmctl
-32 64 dup sys_dup
-33 64 dup2 sys_dup2
-34 64 pause sys_pause
-35 64 nanosleep sys_nanosleep
-36 64 getitimer sys_getitimer
-37 64 alarm sys_alarm
-38 64 setitimer sys_setitimer
-39 64 getpid sys_getpid
-40 64 sendfile sys_sendfile64
-41 64 socket sys_socket
-42 64 connect sys_connect
-43 64 accept sys_accept
-44 64 sendto sys_sendto
-45 64 recvfrom sys_recvfrom
-46 64 sendmsg sys_sendmsg
-47 64 recvmsg sys_recvmsg
-48 64 shutdown sys_shutdown
-49 64 bind sys_bind
-50 64 listen sys_listen
-51 64 getsockname sys_getsockname
-52 64 getpeername sys_getpeername
-53 64 socketpair sys_socketpair
-54 64 setsockopt sys_setsockopt
-55 64 getsockopt sys_getsockopt
-56 64 clone stub_clone
-57 64 fork stub_fork
-58 64 vfork stub_vfork
-59 64 execve stub_execve
-60 64 exit sys_exit
-61 64 wait4 sys_wait4
-62 64 kill sys_kill
-63 64 uname sys_newuname
-64 64 semget sys_semget
-65 64 semop sys_semop
-66 64 semctl sys_semctl
-67 64 shmdt sys_shmdt
-68 64 msgget sys_msgget
-69 64 msgsnd sys_msgsnd
-70 64 msgrcv sys_msgrcv
-71 64 msgctl sys_msgctl
-72 64 fcntl sys_fcntl
-73 64 flock sys_flock
-74 64 fsync sys_fsync
-75 64 fdatasync sys_fdatasync
-76 64 truncate sys_truncate
-77 64 ftruncate sys_ftruncate
-78 64 getdents sys_getdents
-79 64 getcwd sys_getcwd
-80 64 chdir sys_chdir
-81 64 fchdir sys_fchdir
-82 64 rename sys_rename
-83 64 mkdir sys_mkdir
-84 64 rmdir sys_rmdir
-85 64 creat sys_creat
-86 64 link sys_link
-87 64 unlink sys_unlink
-88 64 symlink sys_symlink
-89 64 readlink sys_readlink
-90 64 chmod sys_chmod
-91 64 fchmod sys_fchmod
-92 64 chown sys_chown
-93 64 fchown sys_fchown
-94 64 lchown sys_lchown
-95 64 umask sys_umask
-96 64 gettimeofday sys_gettimeofday
-97 64 getrlimit sys_getrlimit
-98 64 getrusage sys_getrusage
-99 64 sysinfo sys_sysinfo
-100 64 times sys_times
-101 64 ptrace sys_ptrace
-102 64 getuid sys_getuid
-103 64 syslog sys_syslog
-104 64 getgid sys_getgid
-105 64 setuid sys_setuid
-106 64 setgid sys_setgid
-107 64 geteuid sys_geteuid
-108 64 getegid sys_getegid
-109 64 setpgid sys_setpgid
-110 64 getppid sys_getppid
-111 64 getpgrp sys_getpgrp
-112 64 setsid sys_setsid
-113 64 setreuid sys_setreuid
-114 64 setregid sys_setregid
-115 64 getgroups sys_getgroups
-116 64 setgroups sys_setgroups
-117 64 setresuid sys_setresuid
-118 64 getresuid sys_getresuid
-119 64 setresgid sys_setresgid
-120 64 getresgid sys_getresgid
-121 64 getpgid sys_getpgid
-122 64 setfsuid sys_setfsuid
-123 64 setfsgid sys_setfsgid
-124 64 getsid sys_getsid
-125 64 capget sys_capget
-126 64 capset sys_capset
-127 64 rt_sigpending sys_rt_sigpending
-128 64 rt_sigtimedwait sys_rt_sigtimedwait
-129 64 rt_sigqueueinfo sys_rt_sigqueueinfo
-130 64 rt_sigsuspend sys_rt_sigsuspend
-131 64 sigaltstack stub_sigaltstack
-132 64 utime sys_utime
-133 64 mknod sys_mknod
-134 64 uselib
-135 64 personality sys_personality
-136 64 ustat sys_ustat
-137 64 statfs sys_statfs
-138 64 fstatfs sys_fstatfs
-139 64 sysfs sys_sysfs
-140 64 getpriority sys_getpriority
-141 64 setpriority sys_setpriority
-142 64 sched_setparam sys_sched_setparam
-143 64 sched_getparam sys_sched_getparam
-144 64 sched_setscheduler sys_sched_setscheduler
-145 64 sched_getscheduler sys_sched_getscheduler
-146 64 sched_get_priority_max sys_sched_get_priority_max
-147 64 sched_get_priority_min sys_sched_get_priority_min
-148 64 sched_rr_get_interval sys_sched_rr_get_interval
-149 64 mlock sys_mlock
-150 64 munlock sys_munlock
-151 64 mlockall sys_mlockall
-152 64 munlockall sys_munlockall
-153 64 vhangup sys_vhangup
-154 64 modify_ldt sys_modify_ldt
-155 64 pivot_root sys_pivot_root
-156 64 _sysctl sys_sysctl
-157 64 prctl sys_prctl
-158 64 arch_prctl sys_arch_prctl
-159 64 adjtimex sys_adjtimex
-160 64 setrlimit sys_setrlimit
-161 64 chroot sys_chroot
-162 64 sync sys_sync
-163 64 acct sys_acct
-164 64 settimeofday sys_settimeofday
-165 64 mount sys_mount
-166 64 umount2 sys_umount
-167 64 swapon sys_swapon
-168 64 swapoff sys_swapoff
-169 64 reboot sys_reboot
-170 64 sethostname sys_sethostname
-171 64 setdomainname sys_setdomainname
-172 64 iopl stub_iopl
-173 64 ioperm sys_ioperm
-174 64 create_module
-175 64 init_module sys_init_module
-176 64 delete_module sys_delete_module
-177 64 get_kernel_syms
-178 64 query_module
-179 64 quotactl sys_quotactl
-180 64 nfsservctl
-181 64 getpmsg
-182 64 putpmsg
-183 64 afs_syscall
-184 64 tuxcall
-185 64 security
-186 64 gettid sys_gettid
-187 64 readahead sys_readahead
-188 64 setxattr sys_setxattr
-189 64 lsetxattr sys_lsetxattr
-190 64 fsetxattr sys_fsetxattr
-191 64 getxattr sys_getxattr
-192 64 lgetxattr sys_lgetxattr
-193 64 fgetxattr sys_fgetxattr
-194 64 listxattr sys_listxattr
-195 64 llistxattr sys_llistxattr
-196 64 flistxattr sys_flistxattr
-197 64 removexattr sys_removexattr
-198 64 lremovexattr sys_lremovexattr
-199 64 fremovexattr sys_fremovexattr
-200 64 tkill sys_tkill
-201 64 time sys_time
-202 64 futex sys_futex
-203 64 sched_setaffinity sys_sched_setaffinity
-204 64 sched_getaffinity sys_sched_getaffinity
-205 64 set_thread_area
-206 64 io_setup sys_io_setup
-207 64 io_destroy sys_io_destroy
-208 64 io_getevents sys_io_getevents
-209 64 io_submit sys_io_submit
-210 64 io_cancel sys_io_cancel
-211 64 get_thread_area
-212 64 lookup_dcookie sys_lookup_dcookie
-213 64 epoll_create sys_epoll_create
-214 64 epoll_ctl_old
-215 64 epoll_wait_old
-216 64 remap_file_pages sys_remap_file_pages
-217 64 getdents64 sys_getdents64
-218 64 set_tid_address sys_set_tid_address
-219 64 restart_syscall sys_restart_syscall
-220 64 semtimedop sys_semtimedop
-221 64 fadvise64 sys_fadvise64
-222 64 timer_create sys_timer_create
-223 64 timer_settime sys_timer_settime
-224 64 timer_gettime sys_timer_gettime
-225 64 timer_getoverrun sys_timer_getoverrun
-226 64 timer_delete sys_timer_delete
-227 64 clock_settime sys_clock_settime
-228 64 clock_gettime sys_clock_gettime
-229 64 clock_getres sys_clock_getres
-230 64 clock_nanosleep sys_clock_nanosleep
-231 64 exit_group sys_exit_group
-232 64 epoll_wait sys_epoll_wait
-233 64 epoll_ctl sys_epoll_ctl
-234 64 tgkill sys_tgkill
-235 64 utimes sys_utimes
-236 64 vserver
-237 64 mbind sys_mbind
-238 64 set_mempolicy sys_set_mempolicy
-239 64 get_mempolicy sys_get_mempolicy
-240 64 mq_open sys_mq_open
-241 64 mq_unlink sys_mq_unlink
-242 64 mq_timedsend sys_mq_timedsend
-243 64 mq_timedreceive sys_mq_timedreceive
-244 64 mq_notify sys_mq_notify
-245 64 mq_getsetattr sys_mq_getsetattr
-246 64 kexec_load sys_kexec_load
-247 64 waitid sys_waitid
-248 64 add_key sys_add_key
-249 64 request_key sys_request_key
-250 64 keyctl sys_keyctl
-251 64 ioprio_set sys_ioprio_set
-252 64 ioprio_get sys_ioprio_get
-253 64 inotify_init sys_inotify_init
-254 64 inotify_add_watch sys_inotify_add_watch
-255 64 inotify_rm_watch sys_inotify_rm_watch
-256 64 migrate_pages sys_migrate_pages
-257 64 openat sys_openat
-258 64 mkdirat sys_mkdirat
-259 64 mknodat sys_mknodat
-260 64 fchownat sys_fchownat
-261 64 futimesat sys_futimesat
-262 64 newfstatat sys_newfstatat
-263 64 unlinkat sys_unlinkat
-264 64 renameat sys_renameat
-265 64 linkat sys_linkat
-266 64 symlinkat sys_symlinkat
-267 64 readlinkat sys_readlinkat
-268 64 fchmodat sys_fchmodat
-269 64 faccessat sys_faccessat
-270 64 pselect6 sys_pselect6
-271 64 ppoll sys_ppoll
-272 64 unshare sys_unshare
-273 64 set_robust_list sys_set_robust_list
-274 64 get_robust_list sys_get_robust_list
-275 64 splice sys_splice
-276 64 tee sys_tee
-277 64 sync_file_range sys_sync_file_range
-278 64 vmsplice sys_vmsplice
-279 64 move_pages sys_move_pages
-280 64 utimensat sys_utimensat
-281 64 epoll_pwait sys_epoll_pwait
-282 64 signalfd sys_signalfd
-283 64 timerfd_create sys_timerfd_create
-284 64 eventfd sys_eventfd
-285 64 fallocate sys_fallocate
-286 64 timerfd_settime sys_timerfd_settime
-287 64 timerfd_gettime sys_timerfd_gettime
-288 64 accept4 sys_accept4
-289 64 signalfd4 sys_signalfd4
-290 64 eventfd2 sys_eventfd2
-291 64 epoll_create1 sys_epoll_create1
-292 64 dup3 sys_dup3
-293 64 pipe2 sys_pipe2
-294 64 inotify_init1 sys_inotify_init1
-295 64 preadv sys_preadv
-296 64 pwritev sys_pwritev
-297 64 rt_tgsigqueueinfo sys_rt_tgsigqueueinfo
-298 64 perf_event_open sys_perf_event_open
-299 64 recvmmsg sys_recvmmsg
-300 64 fanotify_init sys_fanotify_init
-301 64 fanotify_mark sys_fanotify_mark
-302 64 prlimit64 sys_prlimit64
-303 64 name_to_handle_at sys_name_to_handle_at
-304 64 open_by_handle_at sys_open_by_handle_at
-305 64 clock_adjtime sys_clock_adjtime
-306 64 syncfs sys_syncfs
-307 64 sendmmsg sys_sendmmsg
-308 64 setns sys_setns
-309 64 getcpu sys_getcpu
-310 64 process_vm_readv sys_process_vm_readv
-311 64 process_vm_writev sys_process_vm_writev
diff --git a/trunk/arch/x86/syscalls/syscallhdr.sh b/trunk/arch/x86/syscalls/syscallhdr.sh
deleted file mode 100644
index 31fd5f1f38f7..000000000000
--- a/trunk/arch/x86/syscalls/syscallhdr.sh
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/bin/sh
-
-in="$1"
-out="$2"
-my_abis=`echo "($3)" | tr ',' '|'`
-prefix="$4"
-offset="$5"
-
-fileguard=_ASM_X86_`basename "$out" | sed \
- -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' \
- -e 's/[^A-Z0-9_]/_/g' -e 's/__/_/g'`
-grep -E "^[0-9A-Fa-fXx]+[[:space:]]+${my_abis}" "$in" | sort -n | (
- echo "#ifndef ${fileguard}"
- echo "#define ${fileguard} 1"
- echo ""
-
- while read nr abi name entry ; do
- if [ -z "$offset" ]; then
- echo "#define __NR_${prefix}${name} $nr"
- else
- echo "#define __NR_${prefix}${name} ($offset + $nr)"
- fi
- done
-
- echo ""
- echo "#endif /* ${fileguard} */"
-) > "$out"
diff --git a/trunk/arch/x86/syscalls/syscalltbl.sh b/trunk/arch/x86/syscalls/syscalltbl.sh
deleted file mode 100644
index 0e7f8ec071e7..000000000000
--- a/trunk/arch/x86/syscalls/syscalltbl.sh
+++ /dev/null
@@ -1,15 +0,0 @@
-#!/bin/sh
-
-in="$1"
-out="$2"
-
-grep '^[0-9]' "$in" | sort -n | (
- while read nr abi name entry compat; do
- abi=`echo "$abi" | tr '[a-z]' '[A-Z]'`
- if [ -n "$compat" ]; then
- echo "__SYSCALL_${abi}($nr, $entry, $compat)"
- elif [ -n "$entry" ]; then
- echo "__SYSCALL_${abi}($nr, $entry, $entry)"
- fi
- done
-) > "$out"
diff --git a/trunk/arch/x86/um/Makefile b/trunk/arch/x86/um/Makefile
index 5d065b2222d3..8fb58400e415 100644
--- a/trunk/arch/x86/um/Makefile
+++ b/trunk/arch/x86/um/Makefile
@@ -37,8 +37,7 @@ subarch-$(CONFIG_MODULES) += ../kernel/module.o
USER_OBJS := bugs_$(BITS).o ptrace_user.o fault.o
extra-y += user-offsets.s
-$(obj)/user-offsets.s: c_flags = -Wp,-MD,$(depfile) $(USER_CFLAGS) \
- -Iarch/x86/include/generated
+$(obj)/user-offsets.s: c_flags = -Wp,-MD,$(depfile) $(USER_CFLAGS)
UNPROFILE_OBJS := stub_segv.o
CFLAGS_stub_segv.o := $(CFLAGS_NO_HARDENING)
diff --git a/trunk/arch/x86/um/shared/sysdep/ptrace.h b/trunk/arch/x86/um/shared/sysdep/ptrace.h
index 2bbe1ec2d96a..711b1621747f 100644
--- a/trunk/arch/x86/um/shared/sysdep/ptrace.h
+++ b/trunk/arch/x86/um/shared/sysdep/ptrace.h
@@ -1,15 +1,5 @@
-#ifndef __SYSDEP_X86_PTRACE_H
-#define __SYSDEP_X86_PTRACE_H
-
#ifdef __i386__
#include "ptrace_32.h"
#else
#include "ptrace_64.h"
#endif
-
-static inline long regs_return_value(struct uml_pt_regs *regs)
-{
- return UPT_SYSCALL_RET(regs);
-}
-
-#endif /* __SYSDEP_X86_PTRACE_H */
diff --git a/trunk/arch/x86/um/sys_call_table_32.S b/trunk/arch/x86/um/sys_call_table_32.S
new file mode 100644
index 000000000000..a7ca80d2dceb
--- /dev/null
+++ b/trunk/arch/x86/um/sys_call_table_32.S
@@ -0,0 +1,26 @@
+#include
+/* Steal i386 syscall table for our purposes, but with some slight changes.*/
+
+#define sys_iopl sys_ni_syscall
+#define sys_ioperm sys_ni_syscall
+
+#define sys_vm86old sys_ni_syscall
+#define sys_vm86 sys_ni_syscall
+
+#define old_mmap sys_old_mmap
+
+#define ptregs_fork sys_fork
+#define ptregs_execve sys_execve
+#define ptregs_iopl sys_iopl
+#define ptregs_vm86old sys_vm86old
+#define ptregs_clone sys_clone
+#define ptregs_vm86 sys_vm86
+#define ptregs_sigaltstack sys_sigaltstack
+#define ptregs_vfork sys_vfork
+
+.section .rodata,"a"
+
+#include "../kernel/syscall_table_32.S"
+
+ENTRY(syscall_table_size)
+.long .-sys_call_table
diff --git a/trunk/arch/x86/um/sys_call_table_32.c b/trunk/arch/x86/um/sys_call_table_32.c
deleted file mode 100644
index 416bd40c0eba..000000000000
--- a/trunk/arch/x86/um/sys_call_table_32.c
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * System call table for UML/i386, copied from arch/x86/kernel/syscall_*.c
- * with some changes for UML.
- */
-
-#include
-#include
-#include
-#include
-
-#define __NO_STUBS
-
-/*
- * Below you can see, in terms of #define's, the differences between the x86-64
- * and the UML syscall table.
- */
-
-/* Not going to be implemented by UML, since we have no hardware. */
-#define sys_iopl sys_ni_syscall
-#define sys_ioperm sys_ni_syscall
-
-#define sys_vm86old sys_ni_syscall
-#define sys_vm86 sys_ni_syscall
-
-#define old_mmap sys_old_mmap
-
-#define ptregs_fork sys_fork
-#define ptregs_execve sys_execve
-#define ptregs_iopl sys_iopl
-#define ptregs_vm86old sys_vm86old
-#define ptregs_clone sys_clone
-#define ptregs_vm86 sys_vm86
-#define ptregs_sigaltstack sys_sigaltstack
-#define ptregs_vfork sys_vfork
-
-#define __SYSCALL_I386(nr, sym, compat) extern asmlinkage void sym(void) ;
-#include
-
-#undef __SYSCALL_I386
-#define __SYSCALL_I386(nr, sym, compat) [ nr ] = sym,
-
-typedef void (*sys_call_ptr_t)(void);
-
-extern void sys_ni_syscall(void);
-
-const sys_call_ptr_t sys_call_table[] __cacheline_aligned = {
- /*
- * Smells like a compiler bug -- it doesn't work
- * when the & below is removed.
- */
- [0 ... __NR_syscall_max] = &sys_ni_syscall,
-#include
-};
-
-int syscall_table_size = sizeof(sys_call_table);
diff --git a/trunk/arch/x86/um/sys_call_table_64.c b/trunk/arch/x86/um/sys_call_table_64.c
index fe626c3ba01b..99522f78b162 100644
--- a/trunk/arch/x86/um/sys_call_table_64.c
+++ b/trunk/arch/x86/um/sys_call_table_64.c
@@ -1,12 +1,11 @@
/*
- * System call table for UML/x86-64, copied from arch/x86/kernel/syscall_*.c
+ * System call table for UML/x86-64, copied from arch/x86_64/kernel/syscall.c
* with some changes for UML.
*/
#include
#include
#include
-#include
#define __NO_STUBS
@@ -35,23 +34,31 @@
#define stub_sigaltstack sys_sigaltstack
#define stub_rt_sigreturn sys_rt_sigreturn
-#define __SYSCALL_64(nr, sym, compat) extern asmlinkage void sym(void) ;
-#include
+#define __SYSCALL(nr, sym) extern asmlinkage void sym(void) ;
+#undef _ASM_X86_UNISTD_64_H
+#include "../../x86/include/asm/unistd_64.h"
-#undef __SYSCALL_64
-#define __SYSCALL_64(nr, sym, compat) [ nr ] = sym,
+#undef __SYSCALL
+#define __SYSCALL(nr, sym) [ nr ] = sym,
+#undef _ASM_X86_UNISTD_64_H
typedef void (*sys_call_ptr_t)(void);
extern void sys_ni_syscall(void);
-const sys_call_ptr_t sys_call_table[] __cacheline_aligned = {
- /*
- * Smells like a compiler bug -- it doesn't work
- * when the & below is removed.
- */
- [0 ... __NR_syscall_max] = &sys_ni_syscall,
-#include
+/*
+ * We used to have a trick here which made sure that holes in the
+ * x86_64 table were filled in with sys_ni_syscall, but a comment in
+ * unistd_64.h says that holes aren't allowed, so the trick was
+ * removed.
+ * The trick looked like this
+ * [0 ... UM_NR_syscall_max] = &sys_ni_syscall
+ * before including unistd_64.h - the later initializations overwrote
+ * the sys_ni_syscall filler.
+ */
+
+sys_call_ptr_t sys_call_table[] __cacheline_aligned = {
+#include
};
int syscall_table_size = sizeof(sys_call_table);
diff --git a/trunk/arch/x86/um/user-offsets.c b/trunk/arch/x86/um/user-offsets.c
index 5edf4f4bbf53..ca49be8ddd0c 100644
--- a/trunk/arch/x86/um/user-offsets.c
+++ b/trunk/arch/x86/um/user-offsets.c
@@ -8,18 +8,6 @@
#include
#include
-#ifdef __i386__
-#define __SYSCALL_I386(nr, sym, compat) [nr] = 1,
-static char syscalls[] = {
-#include
-};
-#else
-#define __SYSCALL_64(nr, sym, compat) [nr] = 1,
-static char syscalls[] = {
-#include
-};
-#endif
-
#define DEFINE(sym, val) \
asm volatile("\n->" #sym " %0 " #val : : "i" (val))
@@ -89,7 +77,4 @@ void foo(void)
DEFINE(UM_PROT_READ, PROT_READ);
DEFINE(UM_PROT_WRITE, PROT_WRITE);
DEFINE(UM_PROT_EXEC, PROT_EXEC);
-
- DEFINE(__NR_syscall_max, sizeof(syscalls) - 1);
- DEFINE(NR_syscalls, sizeof(syscalls));
}
diff --git a/trunk/arch/xtensa/kernel/ptrace.c b/trunk/arch/xtensa/kernel/ptrace.c
index 2dff698ab02e..a0d042aa2967 100644
--- a/trunk/arch/xtensa/kernel/ptrace.c
+++ b/trunk/arch/xtensa/kernel/ptrace.c
@@ -334,7 +334,8 @@ void do_syscall_trace_enter(struct pt_regs *regs)
do_syscall_trace();
#if 0
- audit_syscall_entry(current, AUDIT_ARCH_XTENSA..);
+ if (unlikely(current->audit_context))
+ audit_syscall_entry(current, AUDIT_ARCH_XTENSA..);
#endif
}
diff --git a/trunk/block/cfq-iosched.c b/trunk/block/cfq-iosched.c
index ee55019066a1..163263ddd381 100644
--- a/trunk/block/cfq-iosched.c
+++ b/trunk/block/cfq-iosched.c
@@ -3117,17 +3117,18 @@ cfq_should_preempt(struct cfq_data *cfqd, struct cfq_queue *new_cfqq,
*/
static void cfq_preempt_queue(struct cfq_data *cfqd, struct cfq_queue *cfqq)
{
+ struct cfq_queue *old_cfqq = cfqd->active_queue;
+
cfq_log_cfqq(cfqd, cfqq, "preempt");
+ cfq_slice_expired(cfqd, 1);
/*
* workload type is changed, don't save slice, otherwise preempt
* doesn't happen
*/
- if (cfqq_type(cfqd->active_queue) != cfqq_type(cfqq))
+ if (cfqq_type(old_cfqq) != cfqq_type(cfqq))
cfqq->cfqg->saved_workload_slice = 0;
- cfq_slice_expired(cfqd, 1);
-
/*
* Put the new queue at the front of the of the current list,
* so we know that it will be selected next.
diff --git a/trunk/drivers/acpi/Makefile b/trunk/drivers/acpi/Makefile
index c07f44f05f9d..ecb26b4f29a0 100644
--- a/trunk/drivers/acpi/Makefile
+++ b/trunk/drivers/acpi/Makefile
@@ -20,12 +20,11 @@ obj-y += acpi.o \
# All the builtin files are in the "acpi." module_param namespace.
acpi-y += osl.o utils.o reboot.o
acpi-y += atomicio.o
-acpi-y += nvs.o
# sleep related files
acpi-y += wakeup.o
acpi-y += sleep.o
-acpi-$(CONFIG_ACPI_SLEEP) += proc.o
+acpi-$(CONFIG_ACPI_SLEEP) += proc.o nvs.o
#
diff --git a/trunk/drivers/acpi/acpica/Makefile b/trunk/drivers/acpi/acpica/Makefile
index 0ca208b6dcf0..301bd2d388ad 100644
--- a/trunk/drivers/acpi/acpica/Makefile
+++ b/trunk/drivers/acpi/acpica/Makefile
@@ -8,151 +8,41 @@ ccflags-$(CONFIG_ACPI_DEBUG) += -DACPI_DEBUG_OUTPUT
# use acpi.o to put all files here into acpi.o modparam namespace
obj-y += acpi.o
-acpi-y := \
- dsargs.o \
- dscontrol.o \
- dsfield.o \
- dsinit.o \
- dsmethod.o \
- dsmthdat.o \
- dsobject.o \
- dsopcode.o \
- dsutils.o \
- dswexec.o \
- dswload.o \
- dswload2.o \
- dswscope.o \
- dswstate.o
+acpi-y := dsfield.o dsmthdat.o dsopcode.o dswexec.o dswscope.o \
+ dsmethod.o dsobject.o dsutils.o dswload.o dswstate.o \
+ dsinit.o dsargs.o dscontrol.o dswload2.o
-acpi-y += \
- evevent.o \
- evgpe.o \
- evgpeblk.o \
- evgpeinit.o \
- evgpeutil.o \
- evglock.o \
- evmisc.o \
- evregion.o \
- evrgnini.o \
- evsci.o \
- evxface.o \
- evxfevnt.o \
- evxfgpe.o \
- evxfregn.o
+acpi-y += evevent.o evregion.o evsci.o evxfevnt.o \
+ evmisc.o evrgnini.o evxface.o evxfregn.o \
+ evgpe.o evgpeblk.o evgpeinit.o evgpeutil.o evxfgpe.o evglock.o
-acpi-y += \
- exconfig.o \
- exconvrt.o \
- excreate.o \
- exdebug.o \
- exdump.o \
- exfield.o \
- exfldio.o \
- exmutex.o \
- exnames.o \
- exoparg1.o \
- exoparg2.o \
- exoparg3.o \
- exoparg6.o \
- exprep.o \
- exmisc.o \
- exregion.o \
- exresnte.o \
- exresolv.o \
- exresop.o \
- exstore.o \
- exstoren.o \
- exstorob.o \
- exsystem.o \
- exutils.o
+acpi-y += exconfig.o exfield.o exnames.o exoparg6.o exresolv.o exstorob.o\
+ exconvrt.o exfldio.o exoparg1.o exprep.o exresop.o exsystem.o\
+ excreate.o exmisc.o exoparg2.o exregion.o exstore.o exutils.o \
+ exdump.o exmutex.o exoparg3.o exresnte.o exstoren.o exdebug.o
-acpi-y += \
- hwacpi.o \
- hwgpe.o \
- hwpci.o \
- hwregs.o \
- hwsleep.o \
- hwvalid.o \
- hwxface.o
+acpi-y += hwacpi.o hwgpe.o hwregs.o hwsleep.o hwxface.o hwvalid.o hwpci.o
acpi-$(ACPI_FUTURE_USAGE) += hwtimer.o
-acpi-y += \
- nsaccess.o \
- nsalloc.o \
- nsdump.o \
- nseval.o \
- nsinit.o \
- nsload.o \
- nsnames.o \
- nsobject.o \
- nsparse.o \
- nspredef.o \
- nsrepair.o \
- nsrepair2.o \
- nssearch.o \
- nsutils.o \
- nswalk.o \
- nsxfeval.o \
- nsxfname.o \
- nsxfobj.o
+acpi-y += nsaccess.o nsload.o nssearch.o nsxfeval.o \
+ nsalloc.o nseval.o nsnames.o nsutils.o nsxfname.o \
+ nsdump.o nsinit.o nsobject.o nswalk.o nsxfobj.o \
+ nsparse.o nspredef.o nsrepair.o nsrepair2.o
acpi-$(ACPI_FUTURE_USAGE) += nsdumpdv.o
-acpi-y += \
- psargs.o \
- psloop.o \
- psopcode.o \
- psparse.o \
- psscope.o \
- pstree.o \
- psutils.o \
- pswalk.o \
- psxface.o
+acpi-y += psargs.o psparse.o psloop.o pstree.o pswalk.o \
+ psopcode.o psscope.o psutils.o psxface.o
-acpi-y += \
- rsaddr.o \
- rscalc.o \
- rscreate.o \
- rsinfo.o \
- rsio.o \
- rsirq.o \
- rslist.o \
- rsmemory.o \
- rsmisc.o \
- rsserial.o \
- rsutils.o \
- rsxface.o
+acpi-y += rsaddr.o rscreate.o rsinfo.o rsio.o rslist.o rsmisc.o rsxface.o \
+ rscalc.o rsirq.o rsmemory.o rsutils.o
acpi-$(ACPI_FUTURE_USAGE) += rsdump.o
-acpi-y += \
- tbfadt.o \
- tbfind.o \
- tbinstal.o \
- tbutils.o \
- tbxface.o \
- tbxfroot.o
+acpi-y += tbxface.o tbinstal.o tbutils.o tbfind.o tbfadt.o tbxfroot.o
-acpi-y += \
- utaddress.o \
- utalloc.o \
- utcopy.o \
- utdebug.o \
- utdecode.o \
- utdelete.o \
- uteval.o \
- utglobal.o \
- utids.o \
- utinit.o \
- utlock.o \
- utmath.o \
- utmisc.o \
- utmutex.o \
- utobject.o \
- utosi.o \
- utresrc.o \
- utstate.o \
- utxface.o \
- utxferror.o \
- utxfmutex.o
+acpi-y += utalloc.o utdebug.o uteval.o utinit.o utmisc.o utxface.o \
+ utcopy.o utdelete.o utglobal.o utmath.o utobject.o \
+ utstate.o utmutex.o utobject.o utresrc.o utlock.o utids.o \
+ utosi.o utxferror.o utdecode.o
diff --git a/trunk/drivers/acpi/acpica/accommon.h b/trunk/drivers/acpi/acpica/accommon.h
index a44bd424f9f4..e0ba17f0a7c8 100644
--- a/trunk/drivers/acpi/acpica/accommon.h
+++ b/trunk/drivers/acpi/acpica/accommon.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/acconfig.h b/trunk/drivers/acpi/acpica/acconfig.h
index 1f30af613e87..f895a244ca7e 100644
--- a/trunk/drivers/acpi/acpica/acconfig.h
+++ b/trunk/drivers/acpi/acpica/acconfig.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -123,10 +123,6 @@
#define ACPI_MAX_SLEEP 2000 /* Two seconds */
-/* Address Range lists are per-space_id (Memory and I/O only) */
-
-#define ACPI_ADDRESS_RANGE_MAX 2
-
/******************************************************************************
*
* ACPI Specification constants (Do not change unless the specification changes)
@@ -206,10 +202,9 @@
#define ACPI_RSDP_CHECKSUM_LENGTH 20
#define ACPI_RSDP_XCHECKSUM_LENGTH 36
-/* SMBus, GSBus and IPMI bidirectional buffer size */
+/* SMBus and IPMI bidirectional buffer size */
#define ACPI_SMBUS_BUFFER_SIZE 34
-#define ACPI_GSBUS_BUFFER_SIZE 34
#define ACPI_IPMI_BUFFER_SIZE 66
/* _sx_d and _sx_w control methods */
diff --git a/trunk/drivers/acpi/acpica/acdebug.h b/trunk/drivers/acpi/acpica/acdebug.h
index deaa81979561..eb0b1f8dee6d 100644
--- a/trunk/drivers/acpi/acpica/acdebug.h
+++ b/trunk/drivers/acpi/acpica/acdebug.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/acdispat.h b/trunk/drivers/acpi/acpica/acdispat.h
index 5935ba6707e2..2d1b7ffa377a 100644
--- a/trunk/drivers/acpi/acpica/acdispat.h
+++ b/trunk/drivers/acpi/acpica/acdispat.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/acevents.h b/trunk/drivers/acpi/acpica/acevents.h
index c53caa521a30..bea3b4899183 100644
--- a/trunk/drivers/acpi/acpica/acevents.h
+++ b/trunk/drivers/acpi/acpica/acevents.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -162,7 +162,6 @@ acpi_status acpi_ev_initialize_op_regions(void);
acpi_status
acpi_ev_address_space_dispatch(union acpi_operand_object *region_obj,
- union acpi_operand_object *field_obj,
u32 function,
u32 region_offset, u32 bit_width, u64 *value);
diff --git a/trunk/drivers/acpi/acpica/acglobal.h b/trunk/drivers/acpi/acpica/acglobal.h
index 2853f7673f3b..e6652d716e45 100644
--- a/trunk/drivers/acpi/acpica/acglobal.h
+++ b/trunk/drivers/acpi/acpica/acglobal.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -140,19 +140,8 @@ u32 acpi_gbl_trace_flags;
acpi_name acpi_gbl_trace_method_name;
u8 acpi_gbl_system_awake_and_running;
-/*
- * ACPI 5.0 introduces the concept of a "reduced hardware platform", meaning
- * that the ACPI hardware is no longer required. A flag in the FADT indicates
- * a reduced HW machine, and that flag is duplicated here for convenience.
- */
-u8 acpi_gbl_reduced_hardware;
-
#endif
-/* Do not disassemble buffers to resource descriptors */
-
-ACPI_EXTERN u8 ACPI_INIT_GLOBAL(acpi_gbl_no_resource_disassembly, FALSE);
-
/*****************************************************************************
*
* Debug support
@@ -218,7 +207,7 @@ ACPI_EXTERN struct acpi_rw_lock acpi_gbl_namespace_rw_lock;
/*****************************************************************************
*
- * Mutual exclusion within ACPICA subsystem
+ * Mutual exlusion within ACPICA subsystem
*
****************************************************************************/
@@ -306,8 +295,6 @@ ACPI_EXTERN u8 acpi_gbl_acpi_hardware_present;
ACPI_EXTERN u8 acpi_gbl_events_initialized;
ACPI_EXTERN u8 acpi_gbl_osi_data;
ACPI_EXTERN struct acpi_interface_info *acpi_gbl_supported_interfaces;
-ACPI_EXTERN struct acpi_address_range
- *acpi_gbl_address_range_list[ACPI_ADDRESS_RANGE_MAX];
#ifndef DEFINE_ACPI_GLOBALS
diff --git a/trunk/drivers/acpi/acpica/achware.h b/trunk/drivers/acpi/acpica/achware.h
index 677793e938f5..e7213beaafc7 100644
--- a/trunk/drivers/acpi/acpica/achware.h
+++ b/trunk/drivers/acpi/acpica/achware.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/acinterp.h b/trunk/drivers/acpi/acpica/acinterp.h
index eb308635da72..3731e1c34b83 100644
--- a/trunk/drivers/acpi/acpica/acinterp.h
+++ b/trunk/drivers/acpi/acpica/acinterp.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -468,8 +468,6 @@ void acpi_ex_eisa_id_to_string(char *dest, u64 compressed_id);
void acpi_ex_integer_to_string(char *dest, u64 value);
-u8 acpi_is_valid_space_id(u8 space_id);
-
/*
* exregion - default op_region handlers
*/
diff --git a/trunk/drivers/acpi/acpica/aclocal.h b/trunk/drivers/acpi/acpica/aclocal.h
index 3f24068837d5..5552125d8340 100644
--- a/trunk/drivers/acpi/acpica/aclocal.h
+++ b/trunk/drivers/acpi/acpica/aclocal.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -53,7 +53,7 @@ typedef u32 acpi_mutex_handle;
/* Total number of aml opcodes defined */
-#define AML_NUM_OPCODES 0x81
+#define AML_NUM_OPCODES 0x7F
/* Forward declarations */
@@ -249,16 +249,12 @@ struct acpi_create_field_info {
struct acpi_namespace_node *field_node;
struct acpi_namespace_node *register_node;
struct acpi_namespace_node *data_register_node;
- struct acpi_namespace_node *connection_node;
- u8 *resource_buffer;
u32 bank_value;
u32 field_bit_position;
u32 field_bit_length;
- u16 resource_length;
u8 field_flags;
u8 attribute;
u8 field_type;
- u8 access_length;
};
typedef
@@ -319,8 +315,7 @@ struct acpi_name_info {
/*
* Used for ACPI_PTYPE1_FIXED, ACPI_PTYPE1_VAR, ACPI_PTYPE2,
- * ACPI_PTYPE2_MIN, ACPI_PTYPE2_PKG_COUNT, ACPI_PTYPE2_COUNT,
- * ACPI_PTYPE2_FIX_VAR
+ * ACPI_PTYPE2_MIN, ACPI_PTYPE2_PKG_COUNT, ACPI_PTYPE2_COUNT
*/
struct acpi_package_info {
u8 type;
@@ -630,15 +625,6 @@ union acpi_generic_state {
typedef acpi_status(*ACPI_EXECUTE_OP) (struct acpi_walk_state * walk_state);
-/* Address Range info block */
-
-struct acpi_address_range {
- struct acpi_address_range *next;
- struct acpi_namespace_node *region_node;
- acpi_physical_address start_address;
- acpi_physical_address end_address;
-};
-
/*****************************************************************************
*
* Parser typedefs and structs
@@ -965,7 +951,7 @@ struct acpi_port_info {
#define ACPI_RESOURCE_NAME_END_DEPENDENT 0x38
#define ACPI_RESOURCE_NAME_IO 0x40
#define ACPI_RESOURCE_NAME_FIXED_IO 0x48
-#define ACPI_RESOURCE_NAME_FIXED_DMA 0x50
+#define ACPI_RESOURCE_NAME_RESERVED_S1 0x50
#define ACPI_RESOURCE_NAME_RESERVED_S2 0x58
#define ACPI_RESOURCE_NAME_RESERVED_S3 0x60
#define ACPI_RESOURCE_NAME_RESERVED_S4 0x68
@@ -987,9 +973,7 @@ struct acpi_port_info {
#define ACPI_RESOURCE_NAME_EXTENDED_IRQ 0x89
#define ACPI_RESOURCE_NAME_ADDRESS64 0x8A
#define ACPI_RESOURCE_NAME_EXTENDED_ADDRESS64 0x8B
-#define ACPI_RESOURCE_NAME_GPIO 0x8C
-#define ACPI_RESOURCE_NAME_SERIAL_BUS 0x8E
-#define ACPI_RESOURCE_NAME_LARGE_MAX 0x8E
+#define ACPI_RESOURCE_NAME_LARGE_MAX 0x8B
/*****************************************************************************
*
diff --git a/trunk/drivers/acpi/acpica/acmacros.h b/trunk/drivers/acpi/acpica/acmacros.h
index ef338a96f5b2..b7491ee1fba6 100644
--- a/trunk/drivers/acpi/acpica/acmacros.h
+++ b/trunk/drivers/acpi/acpica/acmacros.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/acnamesp.h b/trunk/drivers/acpi/acpica/acnamesp.h
index 2c9e0f049523..79a598c67fe3 100644
--- a/trunk/drivers/acpi/acpica/acnamesp.h
+++ b/trunk/drivers/acpi/acpica/acnamesp.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/acobject.h b/trunk/drivers/acpi/acpica/acobject.h
index c065078ca83b..1055769f2f01 100644
--- a/trunk/drivers/acpi/acpica/acobject.h
+++ b/trunk/drivers/acpi/acpica/acobject.h
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -254,7 +254,6 @@ ACPI_OBJECT_COMMON_HEADER ACPI_COMMON_NOTIFY_INFO};
u32 base_byte_offset; /* Byte offset within containing object */\
u32 value; /* Value to store into the Bank or Index register */\
u8 start_field_bit_offset;/* Bit offset within first field datum (0-63) */\
- u8 access_length; /* For serial regions/fields */
struct acpi_object_field_common { /* COMMON FIELD (for BUFFER, REGION, BANK, and INDEX fields) */
@@ -262,9 +261,7 @@ struct acpi_object_field_common { /* COMMON FIELD (for BUFFER, REGION, BANK, and
};
struct acpi_object_region_field {
- ACPI_OBJECT_COMMON_HEADER ACPI_COMMON_FIELD_INFO u16 resource_length;
- union acpi_operand_object *region_obj; /* Containing op_region object */
- u8 *resource_buffer; /* resource_template for serial regions/fields */
+ ACPI_OBJECT_COMMON_HEADER ACPI_COMMON_FIELD_INFO union acpi_operand_object *region_obj; /* Containing op_region object */
};
struct acpi_object_bank_field {
@@ -361,7 +358,6 @@ typedef enum {
*/
struct acpi_object_extra {
ACPI_OBJECT_COMMON_HEADER struct acpi_namespace_node *method_REG; /* _REG method for this region (if any) */
- struct acpi_namespace_node *scope_node;
void *region_context; /* Region-specific data */
u8 *aml_start;
u32 aml_length;
diff --git a/trunk/drivers/acpi/acpica/acopcode.h b/trunk/drivers/acpi/acpica/acopcode.h
index 9440d053fbb3..bb2ccfad7376 100644
--- a/trunk/drivers/acpi/acpica/acopcode.h
+++ b/trunk/drivers/acpi/acpica/acopcode.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -93,7 +93,6 @@
#define ARGP_CONCAT_OP ARGP_LIST3 (ARGP_TERMARG, ARGP_TERMARG, ARGP_TARGET)
#define ARGP_CONCAT_RES_OP ARGP_LIST3 (ARGP_TERMARG, ARGP_TERMARG, ARGP_TARGET)
#define ARGP_COND_REF_OF_OP ARGP_LIST2 (ARGP_SUPERNAME, ARGP_SUPERNAME)
-#define ARGP_CONNECTFIELD_OP ARGP_LIST1 (ARGP_NAMESTRING)
#define ARGP_CONTINUE_OP ARG_NONE
#define ARGP_COPY_OP ARGP_LIST2 (ARGP_TERMARG, ARGP_SIMPLENAME)
#define ARGP_CREATE_BIT_FIELD_OP ARGP_LIST3 (ARGP_TERMARG, ARGP_TERMARG, ARGP_NAME)
@@ -165,7 +164,6 @@
#define ARGP_RETURN_OP ARGP_LIST1 (ARGP_TERMARG)
#define ARGP_REVISION_OP ARG_NONE
#define ARGP_SCOPE_OP ARGP_LIST3 (ARGP_PKGLENGTH, ARGP_NAME, ARGP_TERMLIST)
-#define ARGP_SERIALFIELD_OP ARGP_LIST1 (ARGP_NAMESTRING)
#define ARGP_SHIFT_LEFT_OP ARGP_LIST3 (ARGP_TERMARG, ARGP_TERMARG, ARGP_TARGET)
#define ARGP_SHIFT_RIGHT_OP ARGP_LIST3 (ARGP_TERMARG, ARGP_TERMARG, ARGP_TARGET)
#define ARGP_SIGNAL_OP ARGP_LIST1 (ARGP_SUPERNAME)
@@ -225,7 +223,6 @@
#define ARGI_CONCAT_OP ARGI_LIST3 (ARGI_COMPUTEDATA,ARGI_COMPUTEDATA, ARGI_TARGETREF)
#define ARGI_CONCAT_RES_OP ARGI_LIST3 (ARGI_BUFFER, ARGI_BUFFER, ARGI_TARGETREF)
#define ARGI_COND_REF_OF_OP ARGI_LIST2 (ARGI_OBJECT_REF, ARGI_TARGETREF)
-#define ARGI_CONNECTFIELD_OP ARGI_INVALID_OPCODE
#define ARGI_CONTINUE_OP ARGI_INVALID_OPCODE
#define ARGI_COPY_OP ARGI_LIST2 (ARGI_ANYTYPE, ARGI_SIMPLE_TARGET)
#define ARGI_CREATE_BIT_FIELD_OP ARGI_LIST3 (ARGI_BUFFER, ARGI_INTEGER, ARGI_REFERENCE)
@@ -297,7 +294,6 @@
#define ARGI_RETURN_OP ARGI_INVALID_OPCODE
#define ARGI_REVISION_OP ARG_NONE
#define ARGI_SCOPE_OP ARGI_INVALID_OPCODE
-#define ARGI_SERIALFIELD_OP ARGI_INVALID_OPCODE
#define ARGI_SHIFT_LEFT_OP ARGI_LIST3 (ARGI_INTEGER, ARGI_INTEGER, ARGI_TARGETREF)
#define ARGI_SHIFT_RIGHT_OP ARGI_LIST3 (ARGI_INTEGER, ARGI_INTEGER, ARGI_TARGETREF)
#define ARGI_SIGNAL_OP ARGI_LIST1 (ARGI_EVENT)
diff --git a/trunk/drivers/acpi/acpica/acparser.h b/trunk/drivers/acpi/acpica/acparser.h
index b725d780d34d..5ea1e06afa20 100644
--- a/trunk/drivers/acpi/acpica/acparser.h
+++ b/trunk/drivers/acpi/acpica/acparser.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/acpredef.h b/trunk/drivers/acpi/acpica/acpredef.h
index bbb34c9be4e8..c445cca490ea 100644
--- a/trunk/drivers/acpi/acpica/acpredef.h
+++ b/trunk/drivers/acpi/acpica/acpredef.h
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -94,14 +94,6 @@
* ACPI_PTYPE2_REV_FIXED: Revision at start, each subpackage is Fixed-length
* (Used for _ART, _FPS)
*
- * ACPI_PTYPE2_FIX_VAR: Each subpackage consists of some fixed-length elements
- * followed by an optional element
- * object type
- * count
- * object type
- * count = 0 (optional)
- * (Used for _DLM)
- *
*****************************************************************************/
enum acpi_return_package_types {
@@ -113,8 +105,7 @@ enum acpi_return_package_types {
ACPI_PTYPE2_PKG_COUNT = 6,
ACPI_PTYPE2_FIXED = 7,
ACPI_PTYPE2_MIN = 8,
- ACPI_PTYPE2_REV_FIXED = 9,
- ACPI_PTYPE2_FIX_VAR = 10
+ ACPI_PTYPE2_REV_FIXED = 9
};
#ifdef ACPI_CREATE_PREDEFINED_TABLE
@@ -163,7 +154,6 @@ static const union acpi_predefined_info predefined_names[] =
{{"_AC8", 0, ACPI_RTYPE_INTEGER}},
{{"_AC9", 0, ACPI_RTYPE_INTEGER}},
{{"_ADR", 0, ACPI_RTYPE_INTEGER}},
- {{"_AEI", 0, ACPI_RTYPE_BUFFER}},
{{"_AL0", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Refs) */
{{{ACPI_PTYPE1_VAR, ACPI_RTYPE_REFERENCE, 0,0}, 0,0}},
@@ -239,13 +229,6 @@ static const union acpi_predefined_info predefined_names[] =
{{"_CID", 0, ACPI_RTYPE_INTEGER | ACPI_RTYPE_STRING | ACPI_RTYPE_PACKAGE}}, /* Variable-length (Ints/Strs) */
{{{ACPI_PTYPE1_VAR, ACPI_RTYPE_INTEGER | ACPI_RTYPE_STRING, 0,0}, 0,0}},
- {{"_CLS", 0, ACPI_RTYPE_PACKAGE}}, /* Fixed-length (3 Int) */
- {{{ACPI_PTYPE1_FIXED, ACPI_RTYPE_INTEGER, 3, 0}, 0, 0}},
-
- {{"_CPC", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Ints/Bufs) */
- {{{ACPI_PTYPE1_VAR, ACPI_RTYPE_INTEGER | ACPI_RTYPE_BUFFER, 0, 0}, 0,
- 0}},
-
{{"_CRS", 0, ACPI_RTYPE_BUFFER}},
{{"_CRT", 0, ACPI_RTYPE_INTEGER}},
{{"_CSD", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (1 Int(n), n-1 Int) */
@@ -254,21 +237,12 @@ static const union acpi_predefined_info predefined_names[] =
{{"_CST", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (1 Int(n), n Pkg (1 Buf/3 Int) */
{{{ACPI_PTYPE2_PKG_COUNT,ACPI_RTYPE_BUFFER, 1, ACPI_RTYPE_INTEGER}, 3,0}},
- {{"_CWS", 1, ACPI_RTYPE_INTEGER}},
{{"_DCK", 1, ACPI_RTYPE_INTEGER}},
{{"_DCS", 0, ACPI_RTYPE_INTEGER}},
{{"_DDC", 1, ACPI_RTYPE_INTEGER | ACPI_RTYPE_BUFFER}},
{{"_DDN", 0, ACPI_RTYPE_STRING}},
- {{"_DEP", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Refs) */
- {{{ACPI_PTYPE1_VAR, ACPI_RTYPE_REFERENCE, 0, 0}, 0, 0}},
-
{{"_DGS", 0, ACPI_RTYPE_INTEGER}},
{{"_DIS", 0, 0}},
-
- {{"_DLM", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Pkgs) each (1 Ref, 0/1 Optional Buf/Ref) */
- {{{ACPI_PTYPE2_FIX_VAR, ACPI_RTYPE_REFERENCE, 1,
- ACPI_RTYPE_REFERENCE | ACPI_RTYPE_BUFFER}, 0, 0}},
-
{{"_DMA", 0, ACPI_RTYPE_BUFFER}},
{{"_DOD", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Ints) */
{{{ACPI_PTYPE1_VAR, ACPI_RTYPE_INTEGER, 0,0}, 0,0}},
@@ -288,7 +262,6 @@ static const union acpi_predefined_info predefined_names[] =
{{"_EJ3", 1, 0}},
{{"_EJ4", 1, 0}},
{{"_EJD", 0, ACPI_RTYPE_STRING}},
- {{"_EVT", 1, 0}},
{{"_FDE", 0, ACPI_RTYPE_BUFFER}},
{{"_FDI", 0, ACPI_RTYPE_PACKAGE}}, /* Fixed-length (16 Int) */
{{{ACPI_PTYPE1_FIXED, ACPI_RTYPE_INTEGER, 16,0}, 0,0}},
@@ -308,17 +281,14 @@ static const union acpi_predefined_info predefined_names[] =
{{{ACPI_PTYPE1_FIXED, ACPI_RTYPE_INTEGER, 3, 0}, 0, 0}},
{{"_GAI", 0, ACPI_RTYPE_INTEGER}},
- {{"_GCP", 0, ACPI_RTYPE_INTEGER}},
{{"_GHL", 0, ACPI_RTYPE_INTEGER}},
{{"_GLK", 0, ACPI_RTYPE_INTEGER}},
{{"_GPD", 0, ACPI_RTYPE_INTEGER}},
{{"_GPE", 0, ACPI_RTYPE_INTEGER}}, /* _GPE method, not _GPE scope */
- {{"_GRT", 0, ACPI_RTYPE_BUFFER}},
{{"_GSB", 0, ACPI_RTYPE_INTEGER}},
{{"_GTF", 0, ACPI_RTYPE_BUFFER}},
{{"_GTM", 0, ACPI_RTYPE_BUFFER}},
{{"_GTS", 1, 0}},
- {{"_GWS", 1, ACPI_RTYPE_INTEGER}},
{{"_HID", 0, ACPI_RTYPE_INTEGER | ACPI_RTYPE_STRING}},
{{"_HOT", 0, ACPI_RTYPE_INTEGER}},
{{"_HPP", 0, ACPI_RTYPE_PACKAGE}}, /* Fixed-length (4 Int) */
@@ -333,7 +303,6 @@ static const union acpi_predefined_info predefined_names[] =
{{"_HPX", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Pkgs) each (var Ints) */
{{{ACPI_PTYPE2_MIN, ACPI_RTYPE_INTEGER, 5,0}, 0,0}},
- {{"_HRV", 0, ACPI_RTYPE_INTEGER}},
{{"_IFT", 0, ACPI_RTYPE_INTEGER}}, /* See IPMI spec */
{{"_INI", 0, 0}},
{{"_IRC", 0, 0}},
@@ -392,9 +361,6 @@ static const union acpi_predefined_info predefined_names[] =
{{"_PR3", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Refs) */
{{{ACPI_PTYPE1_VAR, ACPI_RTYPE_REFERENCE, 0, 0}, 0, 0}},
- {{"_PRE", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Refs) */
- {{{ACPI_PTYPE1_VAR, ACPI_RTYPE_REFERENCE, 0, 0}, 0, 0}},
-
{{"_PRL", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Refs) */
{{{ACPI_PTYPE1_VAR, ACPI_RTYPE_REFERENCE, 0, 0}, 0, 0}},
@@ -425,7 +391,6 @@ static const union acpi_predefined_info predefined_names[] =
{{"_PSD", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Pkgs) each (5 Int) with count */
{{{ACPI_PTYPE2_COUNT, ACPI_RTYPE_INTEGER,0,0}, 0,0}},
- {{"_PSE", 1, 0}},
{{"_PSL", 0, ACPI_RTYPE_PACKAGE}}, /* Variable-length (Refs) */
{{{ACPI_PTYPE1_VAR, ACPI_RTYPE_REFERENCE, 0,0}, 0,0}},
@@ -492,7 +457,6 @@ static const union acpi_predefined_info predefined_names[] =
{{"_SLI", 0, ACPI_RTYPE_BUFFER}},
{{"_SPD", 1, ACPI_RTYPE_INTEGER}},
{{"_SRS", 1, 0}},
- {{"_SRT", 1, ACPI_RTYPE_INTEGER}},
{{"_SRV", 0, ACPI_RTYPE_INTEGER}}, /* See IPMI spec */
{{"_SST", 1, 0}},
{{"_STA", 0, ACPI_RTYPE_INTEGER}},
@@ -500,7 +464,6 @@ static const union acpi_predefined_info predefined_names[] =
{{"_STP", 2, ACPI_RTYPE_INTEGER}},
{{"_STR", 0, ACPI_RTYPE_BUFFER}},
{{"_STV", 2, ACPI_RTYPE_INTEGER}},
- {{"_SUB", 0, ACPI_RTYPE_STRING}},
{{"_SUN", 0, ACPI_RTYPE_INTEGER}},
{{"_SWS", 0, ACPI_RTYPE_INTEGER}},
{{"_TC1", 0, ACPI_RTYPE_INTEGER}},
diff --git a/trunk/drivers/acpi/acpica/acresrc.h b/trunk/drivers/acpi/acpica/acresrc.h
index 0347d0993497..f08b55b7f3a0 100644
--- a/trunk/drivers/acpi/acpica/acresrc.h
+++ b/trunk/drivers/acpi/acpica/acresrc.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -73,40 +73,28 @@ typedef const struct acpi_rsconvert_info {
/* Resource conversion opcodes */
-typedef enum {
- ACPI_RSC_INITGET = 0,
- ACPI_RSC_INITSET,
- ACPI_RSC_FLAGINIT,
- ACPI_RSC_1BITFLAG,
- ACPI_RSC_2BITFLAG,
- ACPI_RSC_3BITFLAG,
- ACPI_RSC_ADDRESS,
- ACPI_RSC_BITMASK,
- ACPI_RSC_BITMASK16,
- ACPI_RSC_COUNT,
- ACPI_RSC_COUNT16,
- ACPI_RSC_COUNT_GPIO_PIN,
- ACPI_RSC_COUNT_GPIO_RES,
- ACPI_RSC_COUNT_GPIO_VEN,
- ACPI_RSC_COUNT_SERIAL_RES,
- ACPI_RSC_COUNT_SERIAL_VEN,
- ACPI_RSC_DATA8,
- ACPI_RSC_EXIT_EQ,
- ACPI_RSC_EXIT_LE,
- ACPI_RSC_EXIT_NE,
- ACPI_RSC_LENGTH,
- ACPI_RSC_MOVE_GPIO_PIN,
- ACPI_RSC_MOVE_GPIO_RES,
- ACPI_RSC_MOVE_SERIAL_RES,
- ACPI_RSC_MOVE_SERIAL_VEN,
- ACPI_RSC_MOVE8,
- ACPI_RSC_MOVE16,
- ACPI_RSC_MOVE32,
- ACPI_RSC_MOVE64,
- ACPI_RSC_SET8,
- ACPI_RSC_SOURCE,
- ACPI_RSC_SOURCEX
-} ACPI_RSCONVERT_OPCODES;
+#define ACPI_RSC_INITGET 0
+#define ACPI_RSC_INITSET 1
+#define ACPI_RSC_FLAGINIT 2
+#define ACPI_RSC_1BITFLAG 3
+#define ACPI_RSC_2BITFLAG 4
+#define ACPI_RSC_COUNT 5
+#define ACPI_RSC_COUNT16 6
+#define ACPI_RSC_LENGTH 7
+#define ACPI_RSC_MOVE8 8
+#define ACPI_RSC_MOVE16 9
+#define ACPI_RSC_MOVE32 10
+#define ACPI_RSC_MOVE64 11
+#define ACPI_RSC_SET8 12
+#define ACPI_RSC_DATA8 13
+#define ACPI_RSC_ADDRESS 14
+#define ACPI_RSC_SOURCE 15
+#define ACPI_RSC_SOURCEX 16
+#define ACPI_RSC_BITMASK 17
+#define ACPI_RSC_BITMASK16 18
+#define ACPI_RSC_EXIT_NE 19
+#define ACPI_RSC_EXIT_LE 20
+#define ACPI_RSC_EXIT_EQ 21
/* Resource Conversion sub-opcodes */
@@ -118,9 +106,6 @@ typedef enum {
#define ACPI_RS_OFFSET(f) (u8) ACPI_OFFSET (struct acpi_resource,f)
#define AML_OFFSET(f) (u8) ACPI_OFFSET (union aml_resource,f)
-/*
- * Individual entry for the resource dump tables
- */
typedef const struct acpi_rsdump_info {
u8 opcode;
u8 offset;
@@ -131,25 +116,20 @@ typedef const struct acpi_rsdump_info {
/* Values for the Opcode field above */
-typedef enum {
- ACPI_RSD_TITLE = 0,
- ACPI_RSD_1BITFLAG,
- ACPI_RSD_2BITFLAG,
- ACPI_RSD_3BITFLAG,
- ACPI_RSD_ADDRESS,
- ACPI_RSD_DWORDLIST,
- ACPI_RSD_LITERAL,
- ACPI_RSD_LONGLIST,
- ACPI_RSD_SHORTLIST,
- ACPI_RSD_SHORTLISTX,
- ACPI_RSD_SOURCE,
- ACPI_RSD_STRING,
- ACPI_RSD_UINT8,
- ACPI_RSD_UINT16,
- ACPI_RSD_UINT32,
- ACPI_RSD_UINT64,
- ACPI_RSD_WORDLIST
-} ACPI_RSDUMP_OPCODES;
+#define ACPI_RSD_TITLE 0
+#define ACPI_RSD_LITERAL 1
+#define ACPI_RSD_STRING 2
+#define ACPI_RSD_UINT8 3
+#define ACPI_RSD_UINT16 4
+#define ACPI_RSD_UINT32 5
+#define ACPI_RSD_UINT64 6
+#define ACPI_RSD_1BITFLAG 7
+#define ACPI_RSD_2BITFLAG 8
+#define ACPI_RSD_SHORTLIST 9
+#define ACPI_RSD_LONGLIST 10
+#define ACPI_RSD_DWORDLIST 11
+#define ACPI_RSD_ADDRESS 12
+#define ACPI_RSD_SOURCE 13
/* restore default alignment */
@@ -158,18 +138,13 @@ typedef enum {
/* Resource tables indexed by internal resource type */
extern const u8 acpi_gbl_aml_resource_sizes[];
-extern const u8 acpi_gbl_aml_resource_serial_bus_sizes[];
extern struct acpi_rsconvert_info *acpi_gbl_set_resource_dispatch[];
/* Resource tables indexed by raw AML resource descriptor type */
extern const u8 acpi_gbl_resource_struct_sizes[];
-extern const u8 acpi_gbl_resource_struct_serial_bus_sizes[];
extern struct acpi_rsconvert_info *acpi_gbl_get_resource_dispatch[];
-extern struct acpi_rsconvert_info
- *acpi_gbl_convert_resource_serial_bus_dispatch[];
-
struct acpi_vendor_walk_info {
struct acpi_vendor_uuid *uuid;
struct acpi_buffer *buffer;
@@ -215,10 +190,6 @@ acpi_status
acpi_rs_set_srs_method_data(struct acpi_namespace_node *node,
struct acpi_buffer *ret_buffer);
-acpi_status
-acpi_rs_get_aei_method_data(struct acpi_namespace_node *node,
- struct acpi_buffer *ret_buffer);
-
/*
* rscalc
*/
@@ -322,11 +293,6 @@ extern struct acpi_rsconvert_info acpi_rs_convert_address16[];
extern struct acpi_rsconvert_info acpi_rs_convert_ext_irq[];
extern struct acpi_rsconvert_info acpi_rs_convert_address64[];
extern struct acpi_rsconvert_info acpi_rs_convert_ext_address64[];
-extern struct acpi_rsconvert_info acpi_rs_convert_gpio[];
-extern struct acpi_rsconvert_info acpi_rs_convert_fixed_dma[];
-extern struct acpi_rsconvert_info acpi_rs_convert_i2c_serial_bus[];
-extern struct acpi_rsconvert_info acpi_rs_convert_spi_serial_bus[];
-extern struct acpi_rsconvert_info acpi_rs_convert_uart_serial_bus[];
/* These resources require separate get/set tables */
@@ -344,7 +310,6 @@ extern struct acpi_rsconvert_info acpi_rs_set_vendor[];
* rsinfo
*/
extern struct acpi_rsdump_info *acpi_gbl_dump_resource_dispatch[];
-extern struct acpi_rsdump_info *acpi_gbl_dump_serial_bus_dispatch[];
/*
* rsdump
@@ -366,12 +331,6 @@ extern struct acpi_rsdump_info acpi_rs_dump_address64[];
extern struct acpi_rsdump_info acpi_rs_dump_ext_address64[];
extern struct acpi_rsdump_info acpi_rs_dump_ext_irq[];
extern struct acpi_rsdump_info acpi_rs_dump_generic_reg[];
-extern struct acpi_rsdump_info acpi_rs_dump_gpio[];
-extern struct acpi_rsdump_info acpi_rs_dump_fixed_dma[];
-extern struct acpi_rsdump_info acpi_rs_dump_common_serial_bus[];
-extern struct acpi_rsdump_info acpi_rs_dump_i2c_serial_bus[];
-extern struct acpi_rsdump_info acpi_rs_dump_spi_serial_bus[];
-extern struct acpi_rsdump_info acpi_rs_dump_uart_serial_bus[];
#endif
#endif /* __ACRESRC_H__ */
diff --git a/trunk/drivers/acpi/acpica/acstruct.h b/trunk/drivers/acpi/acpica/acstruct.h
index 0404df605bc1..1623b245dde2 100644
--- a/trunk/drivers/acpi/acpica/acstruct.h
+++ b/trunk/drivers/acpi/acpica/acstruct.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/actables.h b/trunk/drivers/acpi/acpica/actables.h
index d5bec304c823..967f08124eba 100644
--- a/trunk/drivers/acpi/acpica/actables.h
+++ b/trunk/drivers/acpi/acpica/actables.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/acutils.h b/trunk/drivers/acpi/acpica/acutils.h
index 925ccf22101b..99c140d8e348 100644
--- a/trunk/drivers/acpi/acpica/acutils.h
+++ b/trunk/drivers/acpi/acpica/acutils.h
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -45,7 +45,6 @@
#define _ACUTILS_H
extern const u8 acpi_gbl_resource_aml_sizes[];
-extern const u8 acpi_gbl_resource_aml_serial_bus_sizes[];
/* Strings used by the disassembler and debugger resource dump routines */
@@ -579,24 +578,6 @@ acpi_ut_create_list(char *list_name,
#endif /* ACPI_DBG_TRACK_ALLOCATIONS */
-/*
- * utaddress - address range check
- */
-acpi_status
-acpi_ut_add_address_range(acpi_adr_space_type space_id,
- acpi_physical_address address,
- u32 length, struct acpi_namespace_node *region_node);
-
-void
-acpi_ut_remove_address_range(acpi_adr_space_type space_id,
- struct acpi_namespace_node *region_node);
-
-u32
-acpi_ut_check_address_range(acpi_adr_space_type space_id,
- acpi_physical_address address, u32 length, u8 warn);
-
-void acpi_ut_delete_address_lists(void);
-
/*
* utxferror - various error/warning output functions
*/
diff --git a/trunk/drivers/acpi/acpica/amlcode.h b/trunk/drivers/acpi/acpica/amlcode.h
index 905280fec0fa..1077f17859ed 100644
--- a/trunk/drivers/acpi/acpica/amlcode.h
+++ b/trunk/drivers/acpi/acpica/amlcode.h
@@ -7,7 +7,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -188,14 +188,6 @@
#define AML_LLESSEQUAL_OP (u16) 0x9294
#define AML_LNOTEQUAL_OP (u16) 0x9293
-/*
- * Opcodes for "Field" operators
- */
-#define AML_FIELD_OFFSET_OP (u8) 0x00
-#define AML_FIELD_ACCESS_OP (u8) 0x01
-#define AML_FIELD_CONNECTION_OP (u8) 0x02 /* ACPI 5.0 */
-#define AML_FIELD_EXT_ACCESS_OP (u8) 0x03 /* ACPI 5.0 */
-
/*
* Internal opcodes
* Use only "Unknown" AML opcodes, don't attempt to use
@@ -210,8 +202,6 @@
#define AML_INT_METHODCALL_OP (u16) 0x0035
#define AML_INT_RETURN_VALUE_OP (u16) 0x0036
#define AML_INT_EVAL_SUBTREE_OP (u16) 0x0037
-#define AML_INT_CONNECTION_OP (u16) 0x0038
-#define AML_INT_EXTACCESSFIELD_OP (u16) 0x0039
#define ARG_NONE 0x0
@@ -466,16 +456,13 @@ typedef enum {
* access_as keyword
*/
typedef enum {
- AML_FIELD_ATTRIB_QUICK = 0x02,
- AML_FIELD_ATTRIB_SEND_RCV = 0x04,
- AML_FIELD_ATTRIB_BYTE = 0x06,
- AML_FIELD_ATTRIB_WORD = 0x08,
- AML_FIELD_ATTRIB_BLOCK = 0x0A,
- AML_FIELD_ATTRIB_MULTIBYTE = 0x0B,
- AML_FIELD_ATTRIB_WORD_CALL = 0x0C,
- AML_FIELD_ATTRIB_BLOCK_CALL = 0x0D,
- AML_FIELD_ATTRIB_RAW_BYTES = 0x0E,
- AML_FIELD_ATTRIB_RAW_PROCESS = 0x0F
+ AML_FIELD_ATTRIB_SMB_QUICK = 0x02,
+ AML_FIELD_ATTRIB_SMB_SEND_RCV = 0x04,
+ AML_FIELD_ATTRIB_SMB_BYTE = 0x06,
+ AML_FIELD_ATTRIB_SMB_WORD = 0x08,
+ AML_FIELD_ATTRIB_SMB_BLOCK = 0x0A,
+ AML_FIELD_ATTRIB_SMB_WORD_CALL = 0x0C,
+ AML_FIELD_ATTRIB_SMB_BLOCK_CALL = 0x0D
} AML_ACCESS_ATTRIBUTE;
/* Bit fields in the AML method_flags byte */
diff --git a/trunk/drivers/acpi/acpica/amlresrc.h b/trunk/drivers/acpi/acpica/amlresrc.h
index 7b2128f274e7..59122cde247c 100644
--- a/trunk/drivers/acpi/acpica/amlresrc.h
+++ b/trunk/drivers/acpi/acpica/amlresrc.h
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -58,48 +58,29 @@
#define ACPI_RESTAG_TYPESPECIFICATTRIBUTES "_ATT"
#define ACPI_RESTAG_BASEADDRESS "_BAS"
#define ACPI_RESTAG_BUSMASTER "_BM_" /* Master(1), Slave(0) */
-#define ACPI_RESTAG_DEBOUNCETIME "_DBT"
#define ACPI_RESTAG_DECODE "_DEC"
-#define ACPI_RESTAG_DEVICEPOLARITY "_DPL"
#define ACPI_RESTAG_DMA "_DMA"
#define ACPI_RESTAG_DMATYPE "_TYP" /* Compatible(0), A(1), B(2), F(3) */
-#define ACPI_RESTAG_DRIVESTRENGTH "_DRS"
-#define ACPI_RESTAG_ENDIANNESS "_END"
-#define ACPI_RESTAG_FLOWCONTROL "_FLC"
#define ACPI_RESTAG_GRANULARITY "_GRA"
#define ACPI_RESTAG_INTERRUPT "_INT"
#define ACPI_RESTAG_INTERRUPTLEVEL "_LL_" /* active_lo(1), active_hi(0) */
#define ACPI_RESTAG_INTERRUPTSHARE "_SHR" /* Shareable(1), no_share(0) */
#define ACPI_RESTAG_INTERRUPTTYPE "_HE_" /* Edge(1), Level(0) */
-#define ACPI_RESTAG_IORESTRICTION "_IOR"
#define ACPI_RESTAG_LENGTH "_LEN"
-#define ACPI_RESTAG_LINE "_LIN"
#define ACPI_RESTAG_MEMATTRIBUTES "_MTP" /* Memory(0), Reserved(1), ACPI(2), NVS(3) */
#define ACPI_RESTAG_MEMTYPE "_MEM" /* non_cache(0), Cacheable(1) Cache+combine(2), Cache+prefetch(3) */
#define ACPI_RESTAG_MAXADDR "_MAX"
#define ACPI_RESTAG_MINADDR "_MIN"
#define ACPI_RESTAG_MAXTYPE "_MAF"
#define ACPI_RESTAG_MINTYPE "_MIF"
-#define ACPI_RESTAG_MODE "_MOD"
-#define ACPI_RESTAG_PARITY "_PAR"
-#define ACPI_RESTAG_PHASE "_PHA"
-#define ACPI_RESTAG_PIN "_PIN"
-#define ACPI_RESTAG_PINCONFIG "_PPI"
-#define ACPI_RESTAG_POLARITY "_POL"
#define ACPI_RESTAG_REGISTERBITOFFSET "_RBO"
#define ACPI_RESTAG_REGISTERBITWIDTH "_RBW"
#define ACPI_RESTAG_RANGETYPE "_RNG"
#define ACPI_RESTAG_READWRITETYPE "_RW_" /* read_only(0), Writeable (1) */
-#define ACPI_RESTAG_LENGTH_RX "_RXL"
-#define ACPI_RESTAG_LENGTH_TX "_TXL"
-#define ACPI_RESTAG_SLAVEMODE "_SLV"
-#define ACPI_RESTAG_SPEED "_SPE"
-#define ACPI_RESTAG_STOPBITS "_STB"
#define ACPI_RESTAG_TRANSLATION "_TRA"
#define ACPI_RESTAG_TRANSTYPE "_TRS" /* Sparse(1), Dense(0) */
#define ACPI_RESTAG_TYPE "_TTP" /* Translation(1), Static (0) */
#define ACPI_RESTAG_XFERTYPE "_SIZ" /* 8(0), 8_and16(1), 16(2) */
-#define ACPI_RESTAG_VENDORDATA "_VEN"
/* Default sizes for "small" resource descriptors */
@@ -109,7 +90,6 @@
#define ASL_RDESC_END_DEPEND_SIZE 0x00
#define ASL_RDESC_IO_SIZE 0x07
#define ASL_RDESC_FIXED_IO_SIZE 0x03
-#define ASL_RDESC_FIXED_DMA_SIZE 0x05
#define ASL_RDESC_END_TAG_SIZE 0x01
struct asl_resource_node {
@@ -184,12 +164,6 @@ struct aml_resource_end_tag {
AML_RESOURCE_SMALL_HEADER_COMMON u8 checksum;
};
-struct aml_resource_fixed_dma {
- AML_RESOURCE_SMALL_HEADER_COMMON u16 request_lines;
- u16 channels;
- u8 width;
-};
-
/*
* LARGE descriptors
*/
@@ -289,110 +263,6 @@ struct aml_resource_generic_register {
u64 address;
};
-/* Common descriptor for gpio_int and gpio_io (ACPI 5.0) */
-
-struct aml_resource_gpio {
- AML_RESOURCE_LARGE_HEADER_COMMON u8 revision_id;
- u8 connection_type;
- u16 flags;
- u16 int_flags;
- u8 pin_config;
- u16 drive_strength;
- u16 debounce_timeout;
- u16 pin_table_offset;
- u8 res_source_index;
- u16 res_source_offset;
- u16 vendor_offset;
- u16 vendor_length;
- /*
- * Optional fields follow immediately:
- * 1) PIN list (Words)
- * 2) Resource Source String
- * 3) Vendor Data bytes
- */
-};
-
-#define AML_RESOURCE_GPIO_REVISION 1 /* ACPI 5.0 */
-
-/* Values for connection_type above */
-
-#define AML_RESOURCE_GPIO_TYPE_INT 0
-#define AML_RESOURCE_GPIO_TYPE_IO 1
-#define AML_RESOURCE_MAX_GPIOTYPE 1
-
-/* Common preamble for all serial descriptors (ACPI 5.0) */
-
-#define AML_RESOURCE_SERIAL_COMMON \
- u8 revision_id; \
- u8 res_source_index; \
- u8 type; \
- u8 flags; \
- u16 type_specific_flags; \
- u8 type_revision_id; \
- u16 type_data_length; \
-
-/* Values for the type field above */
-
-#define AML_RESOURCE_I2C_SERIALBUSTYPE 1
-#define AML_RESOURCE_SPI_SERIALBUSTYPE 2
-#define AML_RESOURCE_UART_SERIALBUSTYPE 3
-#define AML_RESOURCE_MAX_SERIALBUSTYPE 3
-#define AML_RESOURCE_VENDOR_SERIALBUSTYPE 192 /* Vendor defined is 0xC0-0xFF (NOT SUPPORTED) */
-
-struct aml_resource_common_serialbus {
-AML_RESOURCE_LARGE_HEADER_COMMON AML_RESOURCE_SERIAL_COMMON};
-
-struct aml_resource_i2c_serialbus {
- AML_RESOURCE_LARGE_HEADER_COMMON
- AML_RESOURCE_SERIAL_COMMON u32 connection_speed;
- u16 slave_address;
- /*
- * Optional fields follow immediately:
- * 1) Vendor Data bytes
- * 2) Resource Source String
- */
-};
-
-#define AML_RESOURCE_I2C_REVISION 1 /* ACPI 5.0 */
-#define AML_RESOURCE_I2C_TYPE_REVISION 1 /* ACPI 5.0 */
-#define AML_RESOURCE_I2C_MIN_DATA_LEN 6
-
-struct aml_resource_spi_serialbus {
- AML_RESOURCE_LARGE_HEADER_COMMON
- AML_RESOURCE_SERIAL_COMMON u32 connection_speed;
- u8 data_bit_length;
- u8 clock_phase;
- u8 clock_polarity;
- u16 device_selection;
- /*
- * Optional fields follow immediately:
- * 1) Vendor Data bytes
- * 2) Resource Source String
- */
-};
-
-#define AML_RESOURCE_SPI_REVISION 1 /* ACPI 5.0 */
-#define AML_RESOURCE_SPI_TYPE_REVISION 1 /* ACPI 5.0 */
-#define AML_RESOURCE_SPI_MIN_DATA_LEN 9
-
-struct aml_resource_uart_serialbus {
- AML_RESOURCE_LARGE_HEADER_COMMON
- AML_RESOURCE_SERIAL_COMMON u32 default_baud_rate;
- u16 rx_fifo_size;
- u16 tx_fifo_size;
- u8 parity;
- u8 lines_enabled;
- /*
- * Optional fields follow immediately:
- * 1) Vendor Data bytes
- * 2) Resource Source String
- */
-};
-
-#define AML_RESOURCE_UART_REVISION 1 /* ACPI 5.0 */
-#define AML_RESOURCE_UART_TYPE_REVISION 1 /* ACPI 5.0 */
-#define AML_RESOURCE_UART_MIN_DATA_LEN 10
-
/* restore default alignment */
#pragma pack()
@@ -414,7 +284,6 @@ union aml_resource {
struct aml_resource_end_dependent end_dpf;
struct aml_resource_io io;
struct aml_resource_fixed_io fixed_io;
- struct aml_resource_fixed_dma fixed_dma;
struct aml_resource_vendor_small vendor_small;
struct aml_resource_end_tag end_tag;
@@ -430,11 +299,6 @@ union aml_resource {
struct aml_resource_address64 address64;
struct aml_resource_extended_address64 ext_address64;
struct aml_resource_extended_irq extended_irq;
- struct aml_resource_gpio gpio;
- struct aml_resource_i2c_serialbus i2c_serial_bus;
- struct aml_resource_spi_serialbus spi_serial_bus;
- struct aml_resource_uart_serialbus uart_serial_bus;
- struct aml_resource_common_serialbus common_serial_bus;
/* Utility overlays */
diff --git a/trunk/drivers/acpi/acpica/dsargs.c b/trunk/drivers/acpi/acpica/dsargs.c
index 80eb1900297f..8c7b99728aa2 100644
--- a/trunk/drivers/acpi/acpica/dsargs.c
+++ b/trunk/drivers/acpi/acpica/dsargs.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -250,13 +250,6 @@ acpi_ds_get_bank_field_arguments(union acpi_operand_object *obj_desc)
status = acpi_ds_execute_arguments(node, node->parent,
extra_desc->extra.aml_length,
extra_desc->extra.aml_start);
- if (ACPI_FAILURE(status)) {
- return_ACPI_STATUS(status);
- }
-
- status = acpi_ut_add_address_range(obj_desc->region.space_id,
- obj_desc->region.address,
- obj_desc->region.length, node);
return_ACPI_STATUS(status);
}
@@ -391,15 +384,8 @@ acpi_status acpi_ds_get_region_arguments(union acpi_operand_object *obj_desc)
/* Execute the argument AML */
- status = acpi_ds_execute_arguments(node, extra_desc->extra.scope_node,
+ status = acpi_ds_execute_arguments(node, node->parent,
extra_desc->extra.aml_length,
extra_desc->extra.aml_start);
- if (ACPI_FAILURE(status)) {
- return_ACPI_STATUS(status);
- }
-
- status = acpi_ut_add_address_range(obj_desc->region.space_id,
- obj_desc->region.address,
- obj_desc->region.length, node);
return_ACPI_STATUS(status);
}
diff --git a/trunk/drivers/acpi/acpica/dscontrol.c b/trunk/drivers/acpi/acpica/dscontrol.c
index effe4ca1133f..26c49fff58da 100644
--- a/trunk/drivers/acpi/acpica/dscontrol.c
+++ b/trunk/drivers/acpi/acpica/dscontrol.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dsfield.c b/trunk/drivers/acpi/acpica/dsfield.c
index cd243cf2cab2..34be60c0e448 100644
--- a/trunk/drivers/acpi/acpica/dsfield.c
+++ b/trunk/drivers/acpi/acpica/dsfield.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -221,7 +221,6 @@ acpi_ds_get_field_names(struct acpi_create_field_info *info,
{
acpi_status status;
u64 position;
- union acpi_parse_object *child;
ACPI_FUNCTION_TRACE_PTR(ds_get_field_names, info);
@@ -233,11 +232,10 @@ acpi_ds_get_field_names(struct acpi_create_field_info *info,
while (arg) {
/*
- * Four types of field elements are handled:
- * 1) Name - Enters a new named field into the namespace
- * 2) Offset - specifies a bit offset
- * 3) access_as - changes the access mode/attributes
- * 4) Connection - Associate a resource template with the field
+ * Three types of field elements are handled:
+ * 1) Offset - specifies a bit offset
+ * 2) access_as - changes the access mode
+ * 3) Name - Enters a new named field into the namespace
*/
switch (arg->common.aml_opcode) {
case AML_INT_RESERVEDFIELD_OP:
@@ -255,70 +253,21 @@ acpi_ds_get_field_names(struct acpi_create_field_info *info,
break;
case AML_INT_ACCESSFIELD_OP:
- case AML_INT_EXTACCESSFIELD_OP:
+
/*
- * Get new access_type, access_attribute, and access_length fields
- * -- to be used for all field units that follow, until the
- * end-of-field or another access_as keyword is encountered.
- * NOTE. These three bytes are encoded in the integer value
- * of the parseop for convenience.
+ * Get a new access_type and access_attribute -- to be used for all
+ * field units that follow, until field end or another access_as
+ * keyword.
*
* In field_flags, preserve the flag bits other than the
- * ACCESS_TYPE bits.
+ * ACCESS_TYPE bits
*/
-
- /* access_type (byte_acc, word_acc, etc.) */
-
info->field_flags = (u8)
((info->
field_flags & ~(AML_FIELD_ACCESS_TYPE_MASK)) |
- ((u8)((u32)(arg->common.value.integer & 0x07))));
-
- /* access_attribute (attrib_quick, attrib_byte, etc.) */
-
- info->attribute =
- (u8)((arg->common.value.integer >> 8) & 0xFF);
-
- /* access_length (for serial/buffer protocols) */
-
- info->access_length =
- (u8)((arg->common.value.integer >> 16) & 0xFF);
- break;
-
- case AML_INT_CONNECTION_OP:
- /*
- * Clear any previous connection. New connection is used for all
- * fields that follow, similar to access_as
- */
- info->resource_buffer = NULL;
- info->connection_node = NULL;
+ ((u8) ((u32) arg->common.value.integer >> 8)));
- /*
- * A Connection() is either an actual resource descriptor (buffer)
- * or a named reference to a resource template
- */
- child = arg->common.value.arg;
- if (child->common.aml_opcode == AML_INT_BYTELIST_OP) {
- info->resource_buffer = child->named.data;
- info->resource_length =
- (u16)child->named.value.integer;
- } else {
- /* Lookup the Connection() namepath, it should already exist */
-
- status = acpi_ns_lookup(walk_state->scope_info,
- child->common.value.
- name, ACPI_TYPE_ANY,
- ACPI_IMODE_EXECUTE,
- ACPI_NS_DONT_OPEN_SCOPE,
- walk_state,
- &info->connection_node);
- if (ACPI_FAILURE(status)) {
- ACPI_ERROR_NAMESPACE(child->common.
- value.name,
- status);
- return_ACPI_STATUS(status);
- }
- }
+ info->attribute = (u8) (arg->common.value.integer);
break;
case AML_INT_NAMEDFIELD_OP:
@@ -425,8 +374,6 @@ acpi_ds_create_field(union acpi_parse_object *op,
}
}
- ACPI_MEMSET(&info, 0, sizeof(struct acpi_create_field_info));
-
/* Second arg is the field flags */
arg = arg->common.next;
@@ -439,6 +386,7 @@ acpi_ds_create_field(union acpi_parse_object *op,
info.region_node = region_node;
status = acpi_ds_get_field_names(&info, walk_state, arg->common.next);
+
return_ACPI_STATUS(status);
}
@@ -526,8 +474,8 @@ acpi_ds_init_field_objects(union acpi_parse_object *op,
*/
while (arg) {
/*
- * Ignore OFFSET/ACCESSAS/CONNECTION terms here; we are only interested
- * in the field names in order to enter them into the namespace.
+ * Ignore OFFSET and ACCESSAS terms here; we are only interested in the
+ * field names in order to enter them into the namespace.
*/
if (arg->common.aml_opcode == AML_INT_NAMEDFIELD_OP) {
status = acpi_ns_lookup(walk_state->scope_info,
@@ -703,5 +651,6 @@ acpi_ds_create_index_field(union acpi_parse_object *op,
info.region_node = region_node;
status = acpi_ds_get_field_names(&info, walk_state, arg->common.next);
+
return_ACPI_STATUS(status);
}
diff --git a/trunk/drivers/acpi/acpica/dsinit.c b/trunk/drivers/acpi/acpica/dsinit.c
index 9e5ac7f780a7..a7718bf2b9a1 100644
--- a/trunk/drivers/acpi/acpica/dsinit.c
+++ b/trunk/drivers/acpi/acpica/dsinit.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dsmethod.c b/trunk/drivers/acpi/acpica/dsmethod.c
index 00f5dab5bcc0..5d797751e205 100644
--- a/trunk/drivers/acpi/acpica/dsmethod.c
+++ b/trunk/drivers/acpi/acpica/dsmethod.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dsmthdat.c b/trunk/drivers/acpi/acpica/dsmthdat.c
index b40bd507be5d..905ce29a92e1 100644
--- a/trunk/drivers/acpi/acpica/dsmthdat.c
+++ b/trunk/drivers/acpi/acpica/dsmthdat.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dsobject.c b/trunk/drivers/acpi/acpica/dsobject.c
index d7045ca3e32a..f42e17e5c252 100644
--- a/trunk/drivers/acpi/acpica/dsobject.c
+++ b/trunk/drivers/acpi/acpica/dsobject.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dsopcode.c b/trunk/drivers/acpi/acpica/dsopcode.c
index e5eff7585102..c627a288e027 100644
--- a/trunk/drivers/acpi/acpica/dsopcode.c
+++ b/trunk/drivers/acpi/acpica/dsopcode.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dsutils.c b/trunk/drivers/acpi/acpica/dsutils.c
index 1abcda31037f..2c477ce172fa 100644
--- a/trunk/drivers/acpi/acpica/dsutils.c
+++ b/trunk/drivers/acpi/acpica/dsutils.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dswexec.c b/trunk/drivers/acpi/acpica/dswexec.c
index 642f3c053e87..fe40e4c6554f 100644
--- a/trunk/drivers/acpi/acpica/dswexec.c
+++ b/trunk/drivers/acpi/acpica/dswexec.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dswload.c b/trunk/drivers/acpi/acpica/dswload.c
index 552aa3a50c84..324acec1179a 100644
--- a/trunk/drivers/acpi/acpica/dswload.c
+++ b/trunk/drivers/acpi/acpica/dswload.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dswload2.c b/trunk/drivers/acpi/acpica/dswload2.c
index ae7147724763..976318138c56 100644
--- a/trunk/drivers/acpi/acpica/dswload2.c
+++ b/trunk/drivers/acpi/acpica/dswload2.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dswscope.c b/trunk/drivers/acpi/acpica/dswscope.c
index 9e9490a9cbf0..76a661fc1e09 100644
--- a/trunk/drivers/acpi/acpica/dswscope.c
+++ b/trunk/drivers/acpi/acpica/dswscope.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/dswstate.c b/trunk/drivers/acpi/acpica/dswstate.c
index c9c2ac13e7cc..a6c374ef9914 100644
--- a/trunk/drivers/acpi/acpica/dswstate.c
+++ b/trunk/drivers/acpi/acpica/dswstate.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evevent.c b/trunk/drivers/acpi/acpica/evevent.c
index 6729ebe2f1e6..d458b041e651 100644
--- a/trunk/drivers/acpi/acpica/evevent.c
+++ b/trunk/drivers/acpi/acpica/evevent.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -71,12 +71,6 @@ acpi_status acpi_ev_initialize_events(void)
ACPI_FUNCTION_TRACE(ev_initialize_events);
- /* If Hardware Reduced flag is set, there are no fixed events */
-
- if (acpi_gbl_reduced_hardware) {
- return_ACPI_STATUS(AE_OK);
- }
-
/*
* Initialize the Fixed and General Purpose Events. This is done prior to
* enabling SCIs to prevent interrupts from occurring before the handlers
@@ -117,12 +111,6 @@ acpi_status acpi_ev_install_xrupt_handlers(void)
ACPI_FUNCTION_TRACE(ev_install_xrupt_handlers);
- /* If Hardware Reduced flag is set, there is no ACPI h/w */
-
- if (acpi_gbl_reduced_hardware) {
- return_ACPI_STATUS(AE_OK);
- }
-
/* Install the SCI handler */
status = acpi_ev_install_sci_handler();
diff --git a/trunk/drivers/acpi/acpica/evglock.c b/trunk/drivers/acpi/acpica/evglock.c
index 5e5683cb1f0d..56a562a1e5d7 100644
--- a/trunk/drivers/acpi/acpica/evglock.c
+++ b/trunk/drivers/acpi/acpica/evglock.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -70,12 +70,6 @@ acpi_status acpi_ev_init_global_lock_handler(void)
ACPI_FUNCTION_TRACE(ev_init_global_lock_handler);
- /* If Hardware Reduced flag is set, there is no global lock */
-
- if (acpi_gbl_reduced_hardware) {
- return_ACPI_STATUS(AE_OK);
- }
-
/* Attempt installation of the global lock handler */
status = acpi_install_fixed_event_handler(ACPI_EVENT_GLOBAL,
diff --git a/trunk/drivers/acpi/acpica/evgpe.c b/trunk/drivers/acpi/acpica/evgpe.c
index 9e88cb6fb25e..65c79add3b19 100644
--- a/trunk/drivers/acpi/acpica/evgpe.c
+++ b/trunk/drivers/acpi/acpica/evgpe.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evgpeblk.c b/trunk/drivers/acpi/acpica/evgpeblk.c
index be75339cd5dd..ca2c41a53311 100644
--- a/trunk/drivers/acpi/acpica/evgpeblk.c
+++ b/trunk/drivers/acpi/acpica/evgpeblk.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evgpeinit.c b/trunk/drivers/acpi/acpica/evgpeinit.c
index adf7494da9db..ce9aa9f9a972 100644
--- a/trunk/drivers/acpi/acpica/evgpeinit.c
+++ b/trunk/drivers/acpi/acpica/evgpeinit.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evgpeutil.c b/trunk/drivers/acpi/acpica/evgpeutil.c
index 25073932aa10..80a81d0c4a80 100644
--- a/trunk/drivers/acpi/acpica/evgpeutil.c
+++ b/trunk/drivers/acpi/acpica/evgpeutil.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evmisc.c b/trunk/drivers/acpi/acpica/evmisc.c
index 84966f416463..d0b331844427 100644
--- a/trunk/drivers/acpi/acpica/evmisc.c
+++ b/trunk/drivers/acpi/acpica/evmisc.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evregion.c b/trunk/drivers/acpi/acpica/evregion.c
index 1b0180a1b798..f0edf5c43c03 100644
--- a/trunk/drivers/acpi/acpica/evregion.c
+++ b/trunk/drivers/acpi/acpica/evregion.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -329,7 +329,6 @@ acpi_ev_execute_reg_method(union acpi_operand_object *region_obj, u32 function)
* FUNCTION: acpi_ev_address_space_dispatch
*
* PARAMETERS: region_obj - Internal region object
- * field_obj - Corresponding field. Can be NULL.
* Function - Read or Write operation
* region_offset - Where in the region to read or write
* bit_width - Field width in bits (8, 16, 32, or 64)
@@ -345,7 +344,6 @@ acpi_ev_execute_reg_method(union acpi_operand_object *region_obj, u32 function)
acpi_status
acpi_ev_address_space_dispatch(union acpi_operand_object *region_obj,
- union acpi_operand_object *field_obj,
u32 function,
u32 region_offset, u32 bit_width, u64 *value)
{
@@ -355,7 +353,6 @@ acpi_ev_address_space_dispatch(union acpi_operand_object *region_obj,
union acpi_operand_object *handler_desc;
union acpi_operand_object *region_obj2;
void *region_context = NULL;
- struct acpi_connection_info *context;
ACPI_FUNCTION_TRACE(ev_address_space_dispatch);
@@ -378,8 +375,6 @@ acpi_ev_address_space_dispatch(union acpi_operand_object *region_obj,
return_ACPI_STATUS(AE_NOT_EXIST);
}
- context = handler_desc->address_space.context;
-
/*
* It may be the case that the region has never been initialized.
* Some types of regions require special init code
@@ -409,7 +404,8 @@ acpi_ev_address_space_dispatch(union acpi_operand_object *region_obj,
acpi_ex_exit_interpreter();
status = region_setup(region_obj, ACPI_REGION_ACTIVATE,
- context, ®ion_context);
+ handler_desc->address_space.context,
+ ®ion_context);
/* Re-enter the interpreter */
@@ -459,25 +455,6 @@ acpi_ev_address_space_dispatch(union acpi_operand_object *region_obj,
acpi_ut_get_region_name(region_obj->region.
space_id)));
- /*
- * Special handling for generic_serial_bus and general_purpose_io:
- * There are three extra parameters that must be passed to the
- * handler via the context:
- * 1) Connection buffer, a resource template from Connection() op.
- * 2) Length of the above buffer.
- * 3) Actual access length from the access_as() op.
- */
- if (((region_obj->region.space_id == ACPI_ADR_SPACE_GSBUS) ||
- (region_obj->region.space_id == ACPI_ADR_SPACE_GPIO)) &&
- context && field_obj) {
-
- /* Get the Connection (resource_template) buffer */
-
- context->connection = field_obj->field.resource_buffer;
- context->length = field_obj->field.resource_length;
- context->access_length = field_obj->field.access_length;
- }
-
if (!(handler_desc->address_space.handler_flags &
ACPI_ADDR_HANDLER_DEFAULT_INSTALLED)) {
/*
@@ -492,7 +469,7 @@ acpi_ev_address_space_dispatch(union acpi_operand_object *region_obj,
status = handler(function,
(region_obj->region.address + region_offset),
- bit_width, value, context,
+ bit_width, value, handler_desc->address_space.context,
region_obj2->extra.region_context);
if (ACPI_FAILURE(status)) {
diff --git a/trunk/drivers/acpi/acpica/evrgnini.c b/trunk/drivers/acpi/acpica/evrgnini.c
index 819c17f5897a..55a5d35ef34a 100644
--- a/trunk/drivers/acpi/acpica/evrgnini.c
+++ b/trunk/drivers/acpi/acpica/evrgnini.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evsci.c b/trunk/drivers/acpi/acpica/evsci.c
index 26065c612e76..2ebd40e1a3ef 100644
--- a/trunk/drivers/acpi/acpica/evsci.c
+++ b/trunk/drivers/acpi/acpica/evsci.c
@@ -6,7 +6,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evxface.c b/trunk/drivers/acpi/acpica/evxface.c
index 61944e89565a..f4f523bf5939 100644
--- a/trunk/drivers/acpi/acpica/evxface.c
+++ b/trunk/drivers/acpi/acpica/evxface.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evxfevnt.c b/trunk/drivers/acpi/acpica/evxfevnt.c
index 1768bbec1002..20516e599476 100644
--- a/trunk/drivers/acpi/acpica/evxfevnt.c
+++ b/trunk/drivers/acpi/acpica/evxfevnt.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evxfgpe.c b/trunk/drivers/acpi/acpica/evxfgpe.c
index 33388fd69df4..f06a3ee356ba 100644
--- a/trunk/drivers/acpi/acpica/evxfgpe.c
+++ b/trunk/drivers/acpi/acpica/evxfgpe.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/evxfregn.c b/trunk/drivers/acpi/acpica/evxfregn.c
index 6019208cd4b6..aee887e3ca5c 100644
--- a/trunk/drivers/acpi/acpica/evxfregn.c
+++ b/trunk/drivers/acpi/acpica/evxfregn.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exconfig.c b/trunk/drivers/acpi/acpica/exconfig.c
index c86d44e41bc8..745a42b401f5 100644
--- a/trunk/drivers/acpi/acpica/exconfig.c
+++ b/trunk/drivers/acpi/acpica/exconfig.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -297,9 +297,9 @@ acpi_ex_region_read(union acpi_operand_object *obj_desc, u32 length, u8 *buffer)
/* Bytewise reads */
for (i = 0; i < length; i++) {
- status =
- acpi_ev_address_space_dispatch(obj_desc, NULL, ACPI_READ,
- region_offset, 8, &value);
+ status = acpi_ev_address_space_dispatch(obj_desc, ACPI_READ,
+ region_offset, 8,
+ &value);
if (ACPI_FAILURE(status)) {
return status;
}
diff --git a/trunk/drivers/acpi/acpica/exconvrt.c b/trunk/drivers/acpi/acpica/exconvrt.c
index e385436bd424..74162a11817d 100644
--- a/trunk/drivers/acpi/acpica/exconvrt.c
+++ b/trunk/drivers/acpi/acpica/exconvrt.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/excreate.c b/trunk/drivers/acpi/acpica/excreate.c
index 3f5bc998c1cb..110711afada8 100644
--- a/trunk/drivers/acpi/acpica/excreate.c
+++ b/trunk/drivers/acpi/acpica/excreate.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -267,7 +267,7 @@ acpi_status acpi_ex_create_mutex(struct acpi_walk_state *walk_state)
*
* PARAMETERS: aml_start - Pointer to the region declaration AML
* aml_length - Max length of the declaration AML
- * space_id - Address space ID for the region
+ * region_space - space_iD for the region
* walk_state - Current state
*
* RETURN: Status
@@ -279,7 +279,7 @@ acpi_status acpi_ex_create_mutex(struct acpi_walk_state *walk_state)
acpi_status
acpi_ex_create_region(u8 * aml_start,
u32 aml_length,
- u8 space_id, struct acpi_walk_state *walk_state)
+ u8 region_space, struct acpi_walk_state *walk_state)
{
acpi_status status;
union acpi_operand_object *obj_desc;
@@ -304,19 +304,16 @@ acpi_ex_create_region(u8 * aml_start,
* Space ID must be one of the predefined IDs, or in the user-defined
* range
*/
- if (!acpi_is_valid_space_id(space_id)) {
- /*
- * Print an error message, but continue. We don't want to abort
- * a table load for this exception. Instead, if the region is
- * actually used at runtime, abort the executing method.
- */
- ACPI_ERROR((AE_INFO,
- "Invalid/unknown Address Space ID: 0x%2.2X",
- space_id));
+ if ((region_space >= ACPI_NUM_PREDEFINED_REGIONS) &&
+ (region_space < ACPI_USER_REGION_BEGIN) &&
+ (region_space != ACPI_ADR_SPACE_DATA_TABLE)) {
+ ACPI_ERROR((AE_INFO, "Invalid AddressSpace type 0x%X",
+ region_space));
+ return_ACPI_STATUS(AE_AML_INVALID_SPACE_ID);
}
ACPI_DEBUG_PRINT((ACPI_DB_LOAD, "Region Type - %s (0x%X)\n",
- acpi_ut_get_region_name(space_id), space_id));
+ acpi_ut_get_region_name(region_space), region_space));
/* Create the region descriptor */
@@ -333,16 +330,10 @@ acpi_ex_create_region(u8 * aml_start,
region_obj2 = obj_desc->common.next_object;
region_obj2->extra.aml_start = aml_start;
region_obj2->extra.aml_length = aml_length;
- if (walk_state->scope_info) {
- region_obj2->extra.scope_node =
- walk_state->scope_info->scope.node;
- } else {
- region_obj2->extra.scope_node = node;
- }
/* Init the region from the operands */
- obj_desc->region.space_id = space_id;
+ obj_desc->region.space_id = region_space;
obj_desc->region.address = 0;
obj_desc->region.length = 0;
obj_desc->region.node = node;
diff --git a/trunk/drivers/acpi/acpica/exdebug.c b/trunk/drivers/acpi/acpica/exdebug.c
index e211e9c19215..c7a2f1edd282 100644
--- a/trunk/drivers/acpi/acpica/exdebug.c
+++ b/trunk/drivers/acpi/acpica/exdebug.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exdump.c b/trunk/drivers/acpi/acpica/exdump.c
index 2a6ac0a3bc1e..61b8c0e8b74d 100644
--- a/trunk/drivers/acpi/acpica/exdump.c
+++ b/trunk/drivers/acpi/acpica/exdump.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -192,13 +192,10 @@ static struct acpi_exdump_info acpi_ex_dump_buffer_field[3] = {
"Buffer Object"}
};
-static struct acpi_exdump_info acpi_ex_dump_region_field[5] = {
+static struct acpi_exdump_info acpi_ex_dump_region_field[3] = {
{ACPI_EXD_INIT, ACPI_EXD_TABLE_SIZE(acpi_ex_dump_region_field), NULL},
{ACPI_EXD_FIELD, 0, NULL},
- {ACPI_EXD_UINT8, ACPI_EXD_OFFSET(field.access_length), "AccessLength"},
- {ACPI_EXD_POINTER, ACPI_EXD_OFFSET(field.region_obj), "Region Object"},
- {ACPI_EXD_POINTER, ACPI_EXD_OFFSET(field.resource_buffer),
- "ResourceBuffer"}
+ {ACPI_EXD_POINTER, ACPI_EXD_OFFSET(field.region_obj), "Region Object"}
};
static struct acpi_exdump_info acpi_ex_dump_bank_field[5] = {
diff --git a/trunk/drivers/acpi/acpica/exfield.c b/trunk/drivers/acpi/acpica/exfield.c
index dc092f5b35d6..0bde2230c028 100644
--- a/trunk/drivers/acpi/acpica/exfield.c
+++ b/trunk/drivers/acpi/acpica/exfield.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -100,25 +100,18 @@ acpi_ex_read_data_from_field(struct acpi_walk_state *walk_state,
(obj_desc->field.region_obj->region.space_id ==
ACPI_ADR_SPACE_SMBUS
|| obj_desc->field.region_obj->region.space_id ==
- ACPI_ADR_SPACE_GSBUS
- || obj_desc->field.region_obj->region.space_id ==
ACPI_ADR_SPACE_IPMI)) {
/*
- * This is an SMBus, GSBus or IPMI read. We must create a buffer to hold
+ * This is an SMBus or IPMI read. We must create a buffer to hold
* the data and then directly access the region handler.
*
- * Note: SMBus and GSBus protocol value is passed in upper 16-bits of Function
+ * Note: Smbus protocol value is passed in upper 16-bits of Function
*/
if (obj_desc->field.region_obj->region.space_id ==
ACPI_ADR_SPACE_SMBUS) {
length = ACPI_SMBUS_BUFFER_SIZE;
function =
ACPI_READ | (obj_desc->field.attribute << 16);
- } else if (obj_desc->field.region_obj->region.space_id ==
- ACPI_ADR_SPACE_GSBUS) {
- length = ACPI_GSBUS_BUFFER_SIZE;
- function =
- ACPI_READ | (obj_desc->field.attribute << 16);
} else { /* IPMI */
length = ACPI_IPMI_BUFFER_SIZE;
@@ -255,23 +248,21 @@ acpi_ex_write_data_to_field(union acpi_operand_object *source_desc,
(obj_desc->field.region_obj->region.space_id ==
ACPI_ADR_SPACE_SMBUS
|| obj_desc->field.region_obj->region.space_id ==
- ACPI_ADR_SPACE_GSBUS
- || obj_desc->field.region_obj->region.space_id ==
ACPI_ADR_SPACE_IPMI)) {
/*
- * This is an SMBus, GSBus or IPMI write. We will bypass the entire field
+ * This is an SMBus or IPMI write. We will bypass the entire field
* mechanism and handoff the buffer directly to the handler. For
* these address spaces, the buffer is bi-directional; on a write,
* return data is returned in the same buffer.
*
* Source must be a buffer of sufficient size:
- * ACPI_SMBUS_BUFFER_SIZE, ACPI_GSBUS_BUFFER_SIZE, or ACPI_IPMI_BUFFER_SIZE.
+ * ACPI_SMBUS_BUFFER_SIZE or ACPI_IPMI_BUFFER_SIZE.
*
- * Note: SMBus and GSBus protocol type is passed in upper 16-bits of Function
+ * Note: SMBus protocol type is passed in upper 16-bits of Function
*/
if (source_desc->common.type != ACPI_TYPE_BUFFER) {
ACPI_ERROR((AE_INFO,
- "SMBus/IPMI/GenericSerialBus write requires Buffer, found type %s",
+ "SMBus or IPMI write requires Buffer, found type %s",
acpi_ut_get_object_type_name(source_desc)));
return_ACPI_STATUS(AE_AML_OPERAND_TYPE);
@@ -282,11 +273,6 @@ acpi_ex_write_data_to_field(union acpi_operand_object *source_desc,
length = ACPI_SMBUS_BUFFER_SIZE;
function =
ACPI_WRITE | (obj_desc->field.attribute << 16);
- } else if (obj_desc->field.region_obj->region.space_id ==
- ACPI_ADR_SPACE_GSBUS) {
- length = ACPI_GSBUS_BUFFER_SIZE;
- function =
- ACPI_WRITE | (obj_desc->field.attribute << 16);
} else { /* IPMI */
length = ACPI_IPMI_BUFFER_SIZE;
@@ -295,7 +281,7 @@ acpi_ex_write_data_to_field(union acpi_operand_object *source_desc,
if (source_desc->buffer.length < length) {
ACPI_ERROR((AE_INFO,
- "SMBus/IPMI/GenericSerialBus write requires Buffer of length %u, found length %u",
+ "SMBus or IPMI write requires Buffer of length %u, found length %u",
length, source_desc->buffer.length));
return_ACPI_STATUS(AE_AML_BUFFER_LIMIT);
diff --git a/trunk/drivers/acpi/acpica/exfldio.c b/trunk/drivers/acpi/acpica/exfldio.c
index 149de45fdadd..f915a7f3f921 100644
--- a/trunk/drivers/acpi/acpica/exfldio.c
+++ b/trunk/drivers/acpi/acpica/exfldio.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -86,7 +86,6 @@ acpi_ex_setup_region(union acpi_operand_object *obj_desc,
{
acpi_status status = AE_OK;
union acpi_operand_object *rgn_desc;
- u8 space_id;
ACPI_FUNCTION_TRACE_U32(ex_setup_region, field_datum_byte_offset);
@@ -102,17 +101,6 @@ acpi_ex_setup_region(union acpi_operand_object *obj_desc,
return_ACPI_STATUS(AE_AML_OPERAND_TYPE);
}
- space_id = rgn_desc->region.space_id;
-
- /* Validate the Space ID */
-
- if (!acpi_is_valid_space_id(space_id)) {
- ACPI_ERROR((AE_INFO,
- "Invalid/unknown Address Space ID: 0x%2.2X",
- space_id));
- return_ACPI_STATUS(AE_AML_INVALID_SPACE_ID);
- }
-
/*
* If the Region Address and Length have not been previously evaluated,
* evaluate them now and save the results.
@@ -131,12 +119,11 @@ acpi_ex_setup_region(union acpi_operand_object *obj_desc,
}
/*
- * Exit now for SMBus, GSBus or IPMI address space, it has a non-linear
+ * Exit now for SMBus or IPMI address space, it has a non-linear
* address space and the request cannot be directly validated
*/
- if (space_id == ACPI_ADR_SPACE_SMBUS ||
- space_id == ACPI_ADR_SPACE_GSBUS ||
- space_id == ACPI_ADR_SPACE_IPMI) {
+ if (rgn_desc->region.space_id == ACPI_ADR_SPACE_SMBUS ||
+ rgn_desc->region.space_id == ACPI_ADR_SPACE_IPMI) {
/* SMBus or IPMI has a non-linear address space */
@@ -284,12 +271,11 @@ acpi_ex_access_region(union acpi_operand_object *obj_desc,
/* Invoke the appropriate address_space/op_region handler */
- status = acpi_ev_address_space_dispatch(rgn_desc, obj_desc,
- function, region_offset,
- ACPI_MUL_8(obj_desc->
- common_field.
- access_byte_width),
- value);
+ status =
+ acpi_ev_address_space_dispatch(rgn_desc, function, region_offset,
+ ACPI_MUL_8(obj_desc->common_field.
+ access_byte_width),
+ value);
if (ACPI_FAILURE(status)) {
if (status == AE_NOT_IMPLEMENTED) {
@@ -330,7 +316,6 @@ acpi_ex_access_region(union acpi_operand_object *obj_desc,
static u8
acpi_ex_register_overflow(union acpi_operand_object *obj_desc, u64 value)
{
- ACPI_FUNCTION_NAME(ex_register_overflow);
if (obj_desc->common_field.bit_length >= ACPI_INTEGER_BIT_SIZE) {
/*
@@ -345,11 +330,6 @@ acpi_ex_register_overflow(union acpi_operand_object *obj_desc, u64 value)
* The Value is larger than the maximum value that can fit into
* the register.
*/
- ACPI_ERROR((AE_INFO,
- "Index value 0x%8.8X%8.8X overflows field width 0x%X",
- ACPI_FORMAT_UINT64(value),
- obj_desc->common_field.bit_length));
-
return (TRUE);
}
diff --git a/trunk/drivers/acpi/acpica/exmisc.c b/trunk/drivers/acpi/acpica/exmisc.c
index 0a0893310348..703d88ed0b3d 100644
--- a/trunk/drivers/acpi/acpica/exmisc.c
+++ b/trunk/drivers/acpi/acpica/exmisc.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exmutex.c b/trunk/drivers/acpi/acpica/exmutex.c
index 60933e9dc3c0..be1c56ead653 100644
--- a/trunk/drivers/acpi/acpica/exmutex.c
+++ b/trunk/drivers/acpi/acpica/exmutex.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exnames.c b/trunk/drivers/acpi/acpica/exnames.c
index fcc75fa27d32..49ec049c157e 100644
--- a/trunk/drivers/acpi/acpica/exnames.c
+++ b/trunk/drivers/acpi/acpica/exnames.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exoparg1.c b/trunk/drivers/acpi/acpica/exoparg1.c
index 9ba8c73cea16..236ead14b7f7 100644
--- a/trunk/drivers/acpi/acpica/exoparg1.c
+++ b/trunk/drivers/acpi/acpica/exoparg1.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exoparg2.c b/trunk/drivers/acpi/acpica/exoparg2.c
index 879e8a277b94..2571b4a310f4 100644
--- a/trunk/drivers/acpi/acpica/exoparg2.c
+++ b/trunk/drivers/acpi/acpica/exoparg2.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exoparg3.c b/trunk/drivers/acpi/acpica/exoparg3.c
index 71fcc65c9ffa..1b48d9d28c9a 100644
--- a/trunk/drivers/acpi/acpica/exoparg3.c
+++ b/trunk/drivers/acpi/acpica/exoparg3.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exoparg6.c b/trunk/drivers/acpi/acpica/exoparg6.c
index 0786b8659061..f4a2787e8e92 100644
--- a/trunk/drivers/acpi/acpica/exoparg6.c
+++ b/trunk/drivers/acpi/acpica/exoparg6.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exprep.c b/trunk/drivers/acpi/acpica/exprep.c
index 30157f5a12d7..cc95e2000406 100644
--- a/trunk/drivers/acpi/acpica/exprep.c
+++ b/trunk/drivers/acpi/acpica/exprep.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -47,7 +47,6 @@
#include "acinterp.h"
#include "amlcode.h"
#include "acnamesp.h"
-#include "acdispat.h"
#define _COMPONENT ACPI_EXECUTER
ACPI_MODULE_NAME("exprep")
@@ -456,30 +455,6 @@ acpi_status acpi_ex_prep_field_value(struct acpi_create_field_info *info)
obj_desc->field.region_obj =
acpi_ns_get_attached_object(info->region_node);
- /* Fields specific to generic_serial_bus fields */
-
- obj_desc->field.access_length = info->access_length;
-
- if (info->connection_node) {
- second_desc = info->connection_node->object;
- if (!(second_desc->common.flags & AOPOBJ_DATA_VALID)) {
- status =
- acpi_ds_get_buffer_arguments(second_desc);
- if (ACPI_FAILURE(status)) {
- acpi_ut_delete_object_desc(obj_desc);
- return_ACPI_STATUS(status);
- }
- }
-
- obj_desc->field.resource_buffer =
- second_desc->buffer.pointer;
- obj_desc->field.resource_length =
- (u16)second_desc->buffer.length;
- } else if (info->resource_buffer) {
- obj_desc->field.resource_buffer = info->resource_buffer;
- obj_desc->field.resource_length = info->resource_length;
- }
-
/* Allow full data read from EC address space */
if ((obj_desc->field.region_obj->region.space_id ==
diff --git a/trunk/drivers/acpi/acpica/exregion.c b/trunk/drivers/acpi/acpica/exregion.c
index 12d51df6d3bf..f0d5e14f1f2c 100644
--- a/trunk/drivers/acpi/acpica/exregion.c
+++ b/trunk/drivers/acpi/acpica/exregion.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exresnte.c b/trunk/drivers/acpi/acpica/exresnte.c
index fa50e77e64a8..55997e46948b 100644
--- a/trunk/drivers/acpi/acpica/exresnte.c
+++ b/trunk/drivers/acpi/acpica/exresnte.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exresolv.c b/trunk/drivers/acpi/acpica/exresolv.c
index 6e335dc34528..db502cd7d934 100644
--- a/trunk/drivers/acpi/acpica/exresolv.c
+++ b/trunk/drivers/acpi/acpica/exresolv.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exresop.c b/trunk/drivers/acpi/acpica/exresop.c
index a67b1d925ddd..e3bb00ccdff5 100644
--- a/trunk/drivers/acpi/acpica/exresop.c
+++ b/trunk/drivers/acpi/acpica/exresop.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exstore.c b/trunk/drivers/acpi/acpica/exstore.c
index c6cf843cc4c9..c0c8842dd344 100644
--- a/trunk/drivers/acpi/acpica/exstore.c
+++ b/trunk/drivers/acpi/acpica/exstore.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exstoren.c b/trunk/drivers/acpi/acpica/exstoren.c
index b35bed52e061..a979017d56b8 100644
--- a/trunk/drivers/acpi/acpica/exstoren.c
+++ b/trunk/drivers/acpi/acpica/exstoren.c
@@ -7,7 +7,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exstorob.c b/trunk/drivers/acpi/acpica/exstorob.c
index 65a45d8335c8..dc665cc554de 100644
--- a/trunk/drivers/acpi/acpica/exstorob.c
+++ b/trunk/drivers/acpi/acpica/exstorob.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exsystem.c b/trunk/drivers/acpi/acpica/exsystem.c
index 191a12945226..df66e7b686be 100644
--- a/trunk/drivers/acpi/acpica/exsystem.c
+++ b/trunk/drivers/acpi/acpica/exsystem.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/exutils.c b/trunk/drivers/acpi/acpica/exutils.c
index eb6798ba8b59..8ad93146dd32 100644
--- a/trunk/drivers/acpi/acpica/exutils.c
+++ b/trunk/drivers/acpi/acpica/exutils.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -435,29 +435,4 @@ void acpi_ex_integer_to_string(char *out_string, u64 value)
}
}
-/*******************************************************************************
- *
- * FUNCTION: acpi_is_valid_space_id
- *
- * PARAMETERS: space_id - ID to be validated
- *
- * RETURN: TRUE if valid/supported ID.
- *
- * DESCRIPTION: Validate an operation region space_iD.
- *
- ******************************************************************************/
-
-u8 acpi_is_valid_space_id(u8 space_id)
-{
-
- if ((space_id >= ACPI_NUM_PREDEFINED_REGIONS) &&
- (space_id < ACPI_USER_REGION_BEGIN) &&
- (space_id != ACPI_ADR_SPACE_DATA_TABLE) &&
- (space_id != ACPI_ADR_SPACE_FIXED_HARDWARE)) {
- return (FALSE);
- }
-
- return (TRUE);
-}
-
#endif
diff --git a/trunk/drivers/acpi/acpica/hwacpi.c b/trunk/drivers/acpi/acpica/hwacpi.c
index d21ec5f0b3a9..fc380d3d45ab 100644
--- a/trunk/drivers/acpi/acpica/hwacpi.c
+++ b/trunk/drivers/acpi/acpica/hwacpi.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/hwgpe.c b/trunk/drivers/acpi/acpica/hwgpe.c
index 1a6894afef79..f610d88a66be 100644
--- a/trunk/drivers/acpi/acpica/hwgpe.c
+++ b/trunk/drivers/acpi/acpica/hwgpe.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/hwpci.c b/trunk/drivers/acpi/acpica/hwpci.c
index 1455ddcdc32c..050fd227951b 100644
--- a/trunk/drivers/acpi/acpica/hwpci.c
+++ b/trunk/drivers/acpi/acpica/hwpci.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/hwregs.c b/trunk/drivers/acpi/acpica/hwregs.c
index 4ea4eeb51bfd..cc70f3fdcdd1 100644
--- a/trunk/drivers/acpi/acpica/hwregs.c
+++ b/trunk/drivers/acpi/acpica/hwregs.c
@@ -7,7 +7,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/hwsleep.c b/trunk/drivers/acpi/acpica/hwsleep.c
index 3c4a922a9fc2..d52da3073650 100644
--- a/trunk/drivers/acpi/acpica/hwsleep.c
+++ b/trunk/drivers/acpi/acpica/hwsleep.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/hwtimer.c b/trunk/drivers/acpi/acpica/hwtimer.c
index d4973d9da9f1..50d21c40b5c1 100644
--- a/trunk/drivers/acpi/acpica/hwtimer.c
+++ b/trunk/drivers/acpi/acpica/hwtimer.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/hwvalid.c b/trunk/drivers/acpi/acpica/hwvalid.c
index 6e5c43a60bb7..5f1605874655 100644
--- a/trunk/drivers/acpi/acpica/hwvalid.c
+++ b/trunk/drivers/acpi/acpica/hwvalid.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -134,8 +134,6 @@ acpi_hw_validate_io_request(acpi_io_address address, u32 bit_width)
/* Supported widths are 8/16/32 */
if ((bit_width != 8) && (bit_width != 16) && (bit_width != 32)) {
- ACPI_ERROR((AE_INFO,
- "Bad BitWidth parameter: %8.8X", bit_width));
return AE_BAD_PARAMETER;
}
diff --git a/trunk/drivers/acpi/acpica/hwxface.c b/trunk/drivers/acpi/acpica/hwxface.c
index 9d38eb6c0d0b..d707756228c2 100644
--- a/trunk/drivers/acpi/acpica/hwxface.c
+++ b/trunk/drivers/acpi/acpica/hwxface.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsaccess.c b/trunk/drivers/acpi/acpica/nsaccess.c
index 61623f3f6826..d93172fd15a8 100644
--- a/trunk/drivers/acpi/acpica/nsaccess.c
+++ b/trunk/drivers/acpi/acpica/nsaccess.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsalloc.c b/trunk/drivers/acpi/acpica/nsalloc.c
index 7c3d3ceb98b3..1d0ef15d158f 100644
--- a/trunk/drivers/acpi/acpica/nsalloc.c
+++ b/trunk/drivers/acpi/acpica/nsalloc.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsdump.c b/trunk/drivers/acpi/acpica/nsdump.c
index b7f2b3be79ac..b683cc2ff9d3 100644
--- a/trunk/drivers/acpi/acpica/nsdump.c
+++ b/trunk/drivers/acpi/acpica/nsdump.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsdumpdv.c b/trunk/drivers/acpi/acpica/nsdumpdv.c
index 30ea5bc53a78..2ed294b7a4db 100644
--- a/trunk/drivers/acpi/acpica/nsdumpdv.c
+++ b/trunk/drivers/acpi/acpica/nsdumpdv.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nseval.c b/trunk/drivers/acpi/acpica/nseval.c
index f375cb82e321..c1bd02b1a058 100644
--- a/trunk/drivers/acpi/acpica/nseval.c
+++ b/trunk/drivers/acpi/acpica/nseval.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsinit.c b/trunk/drivers/acpi/acpica/nsinit.c
index 9d84ec2f0211..fd7c6380e294 100644
--- a/trunk/drivers/acpi/acpica/nsinit.c
+++ b/trunk/drivers/acpi/acpica/nsinit.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsload.c b/trunk/drivers/acpi/acpica/nsload.c
index 5cbf15ffe7d8..5f7dc691c183 100644
--- a/trunk/drivers/acpi/acpica/nsload.c
+++ b/trunk/drivers/acpi/acpica/nsload.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsnames.c b/trunk/drivers/acpi/acpica/nsnames.c
index b20e7c8c3ffb..d5fa520c3de5 100644
--- a/trunk/drivers/acpi/acpica/nsnames.c
+++ b/trunk/drivers/acpi/acpica/nsnames.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsobject.c b/trunk/drivers/acpi/acpica/nsobject.c
index dd77a3ce6e50..3bb8bf105ea2 100644
--- a/trunk/drivers/acpi/acpica/nsobject.c
+++ b/trunk/drivers/acpi/acpica/nsobject.c
@@ -6,7 +6,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsparse.c b/trunk/drivers/acpi/acpica/nsparse.c
index ec7ba2d3463c..b3234fa795b8 100644
--- a/trunk/drivers/acpi/acpica/nsparse.c
+++ b/trunk/drivers/acpi/acpica/nsparse.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nspredef.c b/trunk/drivers/acpi/acpica/nspredef.c
index bbe46a447d34..c845c8089f39 100644
--- a/trunk/drivers/acpi/acpica/nspredef.c
+++ b/trunk/drivers/acpi/acpica/nspredef.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -620,7 +620,6 @@ acpi_ns_check_package(struct acpi_predefined_data *data,
case ACPI_PTYPE2_FIXED:
case ACPI_PTYPE2_MIN:
case ACPI_PTYPE2_COUNT:
- case ACPI_PTYPE2_FIX_VAR:
/*
* These types all return a single Package that consists of a
@@ -760,34 +759,6 @@ acpi_ns_check_package_list(struct acpi_predefined_data *data,
}
break;
- case ACPI_PTYPE2_FIX_VAR:
- /*
- * Each subpackage has a fixed number of elements and an
- * optional element
- */
- expected_count =
- package->ret_info.count1 + package->ret_info.count2;
- if (sub_package->package.count < expected_count) {
- goto package_too_small;
- }
-
- status =
- acpi_ns_check_package_elements(data, sub_elements,
- package->ret_info.
- object_type1,
- package->ret_info.
- count1,
- package->ret_info.
- object_type2,
- sub_package->package.
- count -
- package->ret_info.
- count1, 0);
- if (ACPI_FAILURE(status)) {
- return (status);
- }
- break;
-
case ACPI_PTYPE2_FIXED:
/* Each sub-package has a fixed length */
diff --git a/trunk/drivers/acpi/acpica/nsrepair.c b/trunk/drivers/acpi/acpica/nsrepair.c
index 9c35d20eb52b..ac7b854b0bd7 100644
--- a/trunk/drivers/acpi/acpica/nsrepair.c
+++ b/trunk/drivers/acpi/acpica/nsrepair.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -634,7 +634,6 @@ acpi_ns_remove_null_elements(struct acpi_predefined_data *data,
case ACPI_PTYPE2_FIXED:
case ACPI_PTYPE2_MIN:
case ACPI_PTYPE2_REV_FIXED:
- case ACPI_PTYPE2_FIX_VAR:
break;
default:
diff --git a/trunk/drivers/acpi/acpica/nsrepair2.c b/trunk/drivers/acpi/acpica/nsrepair2.c
index 726bc8e687f7..024c4f263f87 100644
--- a/trunk/drivers/acpi/acpica/nsrepair2.c
+++ b/trunk/drivers/acpi/acpica/nsrepair2.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -467,12 +467,11 @@ acpi_ns_repair_HID(struct acpi_predefined_data *data,
}
/*
- * Copy and uppercase the string. From the ACPI 5.0 specification:
+ * Copy and uppercase the string. From the ACPI specification:
*
* A valid PNP ID must be of the form "AAA####" where A is an uppercase
* letter and # is a hex digit. A valid ACPI ID must be of the form
- * "NNNN####" where N is an uppercase letter or decimal digit, and
- * # is a hex digit.
+ * "ACPI####" where # is a hex digit.
*/
for (dest = new_string->string.pointer; *source; dest++, source++) {
*dest = (char)ACPI_TOUPPER(*source);
diff --git a/trunk/drivers/acpi/acpica/nssearch.c b/trunk/drivers/acpi/acpica/nssearch.c
index 507043d66114..28b0d7a62b99 100644
--- a/trunk/drivers/acpi/acpica/nssearch.c
+++ b/trunk/drivers/acpi/acpica/nssearch.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsutils.c b/trunk/drivers/acpi/acpica/nsutils.c
index a535b7afda5c..cb1b104a69a2 100644
--- a/trunk/drivers/acpi/acpica/nsutils.c
+++ b/trunk/drivers/acpi/acpica/nsutils.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nswalk.c b/trunk/drivers/acpi/acpica/nswalk.c
index f69895a54895..345f0c3c6ad2 100644
--- a/trunk/drivers/acpi/acpica/nswalk.c
+++ b/trunk/drivers/acpi/acpica/nswalk.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsxfeval.c b/trunk/drivers/acpi/acpica/nsxfeval.c
index 71d15f61807b..e7f016d1b226 100644
--- a/trunk/drivers/acpi/acpica/nsxfeval.c
+++ b/trunk/drivers/acpi/acpica/nsxfeval.c
@@ -6,7 +6,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsxfname.c b/trunk/drivers/acpi/acpica/nsxfname.c
index af401c9c4dfc..83bf93024303 100644
--- a/trunk/drivers/acpi/acpica/nsxfname.c
+++ b/trunk/drivers/acpi/acpica/nsxfname.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/nsxfobj.c b/trunk/drivers/acpi/acpica/nsxfobj.c
index 880a605cee20..57e6d825ed84 100644
--- a/trunk/drivers/acpi/acpica/nsxfobj.c
+++ b/trunk/drivers/acpi/acpica/nsxfobj.c
@@ -6,7 +6,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/psargs.c b/trunk/drivers/acpi/acpica/psargs.c
index 5ac36aba507c..e1fad0ee0136 100644
--- a/trunk/drivers/acpi/acpica/psargs.c
+++ b/trunk/drivers/acpi/acpica/psargs.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -484,54 +484,34 @@ acpi_ps_get_next_simple_arg(struct acpi_parse_state *parser_state,
static union acpi_parse_object *acpi_ps_get_next_field(struct acpi_parse_state
*parser_state)
{
- u32 aml_offset;
+ u32 aml_offset = (u32)
+ ACPI_PTR_DIFF(parser_state->aml,
+ parser_state->aml_start);
union acpi_parse_object *field;
- union acpi_parse_object *arg = NULL;
u16 opcode;
u32 name;
- u8 access_type;
- u8 access_attribute;
- u8 access_length;
- u32 pkg_length;
- u8 *pkg_end;
- u32 buffer_length;
ACPI_FUNCTION_TRACE(ps_get_next_field);
- aml_offset =
- (u32)ACPI_PTR_DIFF(parser_state->aml, parser_state->aml_start);
-
/* Determine field type */
switch (ACPI_GET8(parser_state->aml)) {
- case AML_FIELD_OFFSET_OP:
-
- opcode = AML_INT_RESERVEDFIELD_OP;
- parser_state->aml++;
- break;
-
- case AML_FIELD_ACCESS_OP:
+ default:
- opcode = AML_INT_ACCESSFIELD_OP;
- parser_state->aml++;
+ opcode = AML_INT_NAMEDFIELD_OP;
break;
- case AML_FIELD_CONNECTION_OP:
+ case 0x00:
- opcode = AML_INT_CONNECTION_OP;
+ opcode = AML_INT_RESERVEDFIELD_OP;
parser_state->aml++;
break;
- case AML_FIELD_EXT_ACCESS_OP:
+ case 0x01:
- opcode = AML_INT_EXTACCESSFIELD_OP;
+ opcode = AML_INT_ACCESSFIELD_OP;
parser_state->aml++;
break;
-
- default:
-
- opcode = AML_INT_NAMEDFIELD_OP;
- break;
}
/* Allocate a new field op */
@@ -569,111 +549,16 @@ static union acpi_parse_object *acpi_ps_get_next_field(struct acpi_parse_state
break;
case AML_INT_ACCESSFIELD_OP:
- case AML_INT_EXTACCESSFIELD_OP:
/*
* Get access_type and access_attrib and merge into the field Op
- * access_type is first operand, access_attribute is second. stuff
- * these bytes into the node integer value for convenience.
+ * access_type is first operand, access_attribute is second
*/
-
- /* Get the two bytes (Type/Attribute) */
-
- access_type = ACPI_GET8(parser_state->aml);
+ field->common.value.integer =
+ (((u32) ACPI_GET8(parser_state->aml) << 8));
parser_state->aml++;
- access_attribute = ACPI_GET8(parser_state->aml);
+ field->common.value.integer |= ACPI_GET8(parser_state->aml);
parser_state->aml++;
-
- field->common.value.integer = (u8)access_type;
- field->common.value.integer |= (u16)(access_attribute << 8);
-
- /* This opcode has a third byte, access_length */
-
- if (opcode == AML_INT_EXTACCESSFIELD_OP) {
- access_length = ACPI_GET8(parser_state->aml);
- parser_state->aml++;
-
- field->common.value.integer |=
- (u32)(access_length << 16);
- }
- break;
-
- case AML_INT_CONNECTION_OP:
-
- /*
- * Argument for Connection operator can be either a Buffer
- * (resource descriptor), or a name_string.
- */
- if (ACPI_GET8(parser_state->aml) == AML_BUFFER_OP) {
- parser_state->aml++;
-
- pkg_end = parser_state->aml;
- pkg_length =
- acpi_ps_get_next_package_length(parser_state);
- pkg_end += pkg_length;
-
- if (parser_state->aml < pkg_end) {
-
- /* Non-empty list */
-
- arg = acpi_ps_alloc_op(AML_INT_BYTELIST_OP);
- if (!arg) {
- return_PTR(NULL);
- }
-
- /* Get the actual buffer length argument */
-
- opcode = ACPI_GET8(parser_state->aml);
- parser_state->aml++;
-
- switch (opcode) {
- case AML_BYTE_OP: /* AML_BYTEDATA_ARG */
- buffer_length =
- ACPI_GET8(parser_state->aml);
- parser_state->aml += 1;
- break;
-
- case AML_WORD_OP: /* AML_WORDDATA_ARG */
- buffer_length =
- ACPI_GET16(parser_state->aml);
- parser_state->aml += 2;
- break;
-
- case AML_DWORD_OP: /* AML_DWORDATA_ARG */
- buffer_length =
- ACPI_GET32(parser_state->aml);
- parser_state->aml += 4;
- break;
-
- default:
- buffer_length = 0;
- break;
- }
-
- /* Fill in bytelist data */
-
- arg->named.value.size = buffer_length;
- arg->named.data = parser_state->aml;
- }
-
- /* Skip to End of byte data */
-
- parser_state->aml = pkg_end;
- } else {
- arg = acpi_ps_alloc_op(AML_INT_NAMEPATH_OP);
- if (!arg) {
- return_PTR(NULL);
- }
-
- /* Get the Namestring argument */
-
- arg->common.value.name =
- acpi_ps_get_next_namestring(parser_state);
- }
-
- /* Link the buffer/namestring to parent (CONNECTION_OP) */
-
- acpi_ps_append_arg(field, arg);
break;
default:
diff --git a/trunk/drivers/acpi/acpica/psloop.c b/trunk/drivers/acpi/acpica/psloop.c
index 9547ad8a620b..01dd70d1de51 100644
--- a/trunk/drivers/acpi/acpica/psloop.c
+++ b/trunk/drivers/acpi/acpica/psloop.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/psopcode.c b/trunk/drivers/acpi/acpica/psopcode.c
index a0226fdcf75c..bed08de7528c 100644
--- a/trunk/drivers/acpi/acpica/psopcode.c
+++ b/trunk/drivers/acpi/acpica/psopcode.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -638,16 +638,7 @@ const struct acpi_opcode_info acpi_gbl_aml_op_info[AML_NUM_OPCODES] = {
/* 7E */ ACPI_OP("Timer", ARGP_TIMER_OP, ARGI_TIMER_OP, ACPI_TYPE_ANY,
AML_CLASS_EXECUTE, AML_TYPE_EXEC_0A_0T_1R,
- AML_FLAGS_EXEC_0A_0T_1R),
-
-/* ACPI 5.0 opcodes */
-
-/* 7F */ ACPI_OP("-ConnectField-", ARGP_CONNECTFIELD_OP,
- ARGI_CONNECTFIELD_OP, ACPI_TYPE_ANY,
- AML_CLASS_INTERNAL, AML_TYPE_BOGUS, AML_HAS_ARGS),
-/* 80 */ ACPI_OP("-ExtAccessField-", ARGP_CONNECTFIELD_OP,
- ARGI_CONNECTFIELD_OP, ACPI_TYPE_ANY,
- AML_CLASS_INTERNAL, AML_TYPE_BOGUS, 0)
+ AML_FLAGS_EXEC_0A_0T_1R)
/*! [End] no source code translation !*/
};
@@ -666,7 +657,7 @@ static const u8 acpi_gbl_short_op_index[256] = {
/* 0x20 */ _UNK, _UNK, _UNK, _UNK, _UNK, _UNK, _UNK, _UNK,
/* 0x28 */ _UNK, _UNK, _UNK, _UNK, _UNK, 0x63, _PFX, _PFX,
/* 0x30 */ 0x67, 0x66, 0x68, 0x65, 0x69, 0x64, 0x6A, 0x7D,
-/* 0x38 */ 0x7F, 0x80, _UNK, _UNK, _UNK, _UNK, _UNK, _UNK,
+/* 0x38 */ _UNK, _UNK, _UNK, _UNK, _UNK, _UNK, _UNK, _UNK,
/* 0x40 */ _UNK, _ASC, _ASC, _ASC, _ASC, _ASC, _ASC, _ASC,
/* 0x48 */ _ASC, _ASC, _ASC, _ASC, _ASC, _ASC, _ASC, _ASC,
/* 0x50 */ _ASC, _ASC, _ASC, _ASC, _ASC, _ASC, _ASC, _ASC,
diff --git a/trunk/drivers/acpi/acpica/psparse.c b/trunk/drivers/acpi/acpica/psparse.c
index 2ff9c35a1968..9bb0cbd37b5e 100644
--- a/trunk/drivers/acpi/acpica/psparse.c
+++ b/trunk/drivers/acpi/acpica/psparse.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/psscope.c b/trunk/drivers/acpi/acpica/psscope.c
index c872aa4b926e..a5faa1323a02 100644
--- a/trunk/drivers/acpi/acpica/psscope.c
+++ b/trunk/drivers/acpi/acpica/psscope.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/pstree.c b/trunk/drivers/acpi/acpica/pstree.c
index 2b03cdbbe1c0..f1464c03aa42 100644
--- a/trunk/drivers/acpi/acpica/pstree.c
+++ b/trunk/drivers/acpi/acpica/pstree.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -74,12 +74,6 @@ union acpi_parse_object *acpi_ps_get_arg(union acpi_parse_object *op, u32 argn)
ACPI_FUNCTION_ENTRY();
-/*
- if (Op->Common.aml_opcode == AML_INT_CONNECTION_OP)
- {
- return (Op->Common.Value.Arg);
- }
-*/
/* Get the info structure for this opcode */
op_info = acpi_ps_get_opcode_info(op->common.aml_opcode);
diff --git a/trunk/drivers/acpi/acpica/psutils.c b/trunk/drivers/acpi/acpica/psutils.c
index 13bb131ae125..7eda78503422 100644
--- a/trunk/drivers/acpi/acpica/psutils.c
+++ b/trunk/drivers/acpi/acpica/psutils.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/pswalk.c b/trunk/drivers/acpi/acpica/pswalk.c
index ab96cf47896d..3312d6368bf1 100644
--- a/trunk/drivers/acpi/acpica/pswalk.c
+++ b/trunk/drivers/acpi/acpica/pswalk.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/psxface.c b/trunk/drivers/acpi/acpica/psxface.c
index 9d98c5ff66a5..8086805d4494 100644
--- a/trunk/drivers/acpi/acpica/psxface.c
+++ b/trunk/drivers/acpi/acpica/psxface.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/rsaddr.c b/trunk/drivers/acpi/acpica/rsaddr.c
index a0305652394f..9e66f9078426 100644
--- a/trunk/drivers/acpi/acpica/rsaddr.c
+++ b/trunk/drivers/acpi/acpica/rsaddr.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/rscalc.c b/trunk/drivers/acpi/acpica/rscalc.c
index 3c6df4b7eb2d..3a8a89ec2ca4 100644
--- a/trunk/drivers/acpi/acpica/rscalc.c
+++ b/trunk/drivers/acpi/acpica/rscalc.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -313,38 +313,6 @@ acpi_rs_get_aml_length(struct acpi_resource * resource, acpi_size * size_needed)
resource_source));
break;
- case ACPI_RESOURCE_TYPE_GPIO:
-
- total_size =
- (acpi_rs_length) (total_size +
- (resource->data.gpio.
- pin_table_length * 2) +
- resource->data.gpio.
- resource_source.string_length +
- resource->data.gpio.
- vendor_length);
-
- break;
-
- case ACPI_RESOURCE_TYPE_SERIAL_BUS:
-
- total_size =
- acpi_gbl_aml_resource_serial_bus_sizes[resource->
- data.
- common_serial_bus.
- type];
-
- total_size = (acpi_rs_length) (total_size +
- resource->data.
- i2c_serial_bus.
- resource_source.
- string_length +
- resource->data.
- i2c_serial_bus.
- vendor_length);
-
- break;
-
default:
break;
}
@@ -394,11 +362,10 @@ acpi_rs_get_list_length(u8 * aml_buffer,
u32 extra_struct_bytes;
u8 resource_index;
u8 minimum_aml_resource_length;
- union aml_resource *aml_resource;
ACPI_FUNCTION_TRACE(rs_get_list_length);
- *size_needed = ACPI_RS_SIZE_MIN; /* Minimum size is one end_tag */
+ *size_needed = 0;
end_aml = aml_buffer + aml_buffer_length;
/* Walk the list of AML resource descriptors */
@@ -409,15 +376,9 @@ acpi_rs_get_list_length(u8 * aml_buffer,
status = acpi_ut_validate_resource(aml_buffer, &resource_index);
if (ACPI_FAILURE(status)) {
- /*
- * Exit on failure. Cannot continue because the descriptor length
- * may be bogus also.
- */
return_ACPI_STATUS(status);
}
- aml_resource = (void *)aml_buffer;
-
/* Get the resource length and base (minimum) AML size */
resource_length = acpi_ut_get_resource_length(aml_buffer);
@@ -461,8 +422,10 @@ acpi_rs_get_list_length(u8 * aml_buffer,
case ACPI_RESOURCE_NAME_END_TAG:
/*
- * End Tag: This is the normal exit
+ * End Tag:
+ * This is the normal exit, add size of end_tag
*/
+ *size_needed += ACPI_RS_SIZE_MIN;
return_ACPI_STATUS(AE_OK);
case ACPI_RESOURCE_NAME_ADDRESS32:
@@ -494,33 +457,6 @@ acpi_rs_get_list_length(u8 * aml_buffer,
minimum_aml_resource_length);
break;
- case ACPI_RESOURCE_NAME_GPIO:
-
- /* Vendor data is optional */
-
- if (aml_resource->gpio.vendor_length) {
- extra_struct_bytes +=
- aml_resource->gpio.vendor_offset -
- aml_resource->gpio.pin_table_offset +
- aml_resource->gpio.vendor_length;
- } else {
- extra_struct_bytes +=
- aml_resource->large_header.resource_length +
- sizeof(struct aml_resource_large_header) -
- aml_resource->gpio.pin_table_offset;
- }
- break;
-
- case ACPI_RESOURCE_NAME_SERIAL_BUS:
-
- minimum_aml_resource_length =
- acpi_gbl_resource_aml_serial_bus_sizes
- [aml_resource->common_serial_bus.type];
- extra_struct_bytes +=
- aml_resource->common_serial_bus.resource_length -
- minimum_aml_resource_length;
- break;
-
default:
break;
}
@@ -531,18 +467,9 @@ acpi_rs_get_list_length(u8 * aml_buffer,
* Important: Round the size up for the appropriate alignment. This
* is a requirement on IA64.
*/
- if (acpi_ut_get_resource_type(aml_buffer) ==
- ACPI_RESOURCE_NAME_SERIAL_BUS) {
- buffer_size =
- acpi_gbl_resource_struct_serial_bus_sizes
- [aml_resource->common_serial_bus.type] +
- extra_struct_bytes;
- } else {
- buffer_size =
- acpi_gbl_resource_struct_sizes[resource_index] +
- extra_struct_bytes;
- }
- buffer_size = (u32)ACPI_ROUND_UP_TO_NATIVE_WORD(buffer_size);
+ buffer_size = acpi_gbl_resource_struct_sizes[resource_index] +
+ extra_struct_bytes;
+ buffer_size = (u32) ACPI_ROUND_UP_TO_NATIVE_WORD(buffer_size);
*size_needed += buffer_size;
diff --git a/trunk/drivers/acpi/acpica/rscreate.c b/trunk/drivers/acpi/acpica/rscreate.c
index 46d6eb38ae66..4ce6e1147e80 100644
--- a/trunk/drivers/acpi/acpica/rscreate.c
+++ b/trunk/drivers/acpi/acpica/rscreate.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -49,70 +49,6 @@
#define _COMPONENT ACPI_RESOURCES
ACPI_MODULE_NAME("rscreate")
-/*******************************************************************************
- *
- * FUNCTION: acpi_buffer_to_resource
- *
- * PARAMETERS: aml_buffer - Pointer to the resource byte stream
- * aml_buffer_length - Length of the aml_buffer
- * resource_ptr - Where the converted resource is returned
- *
- * RETURN: Status
- *
- * DESCRIPTION: Convert a raw AML buffer to a resource list
- *
- ******************************************************************************/
-acpi_status
-acpi_buffer_to_resource(u8 *aml_buffer,
- u16 aml_buffer_length,
- struct acpi_resource **resource_ptr)
-{
- acpi_status status;
- acpi_size list_size_needed;
- void *resource;
- void *current_resource_ptr;
-
- /*
- * Note: we allow AE_AML_NO_RESOURCE_END_TAG, since an end tag
- * is not required here.
- */
-
- /* Get the required length for the converted resource */
-
- status = acpi_rs_get_list_length(aml_buffer, aml_buffer_length,
- &list_size_needed);
- if (status == AE_AML_NO_RESOURCE_END_TAG) {
- status = AE_OK;
- }
- if (ACPI_FAILURE(status)) {
- return (status);
- }
-
- /* Allocate a buffer for the converted resource */
-
- resource = ACPI_ALLOCATE_ZEROED(list_size_needed);
- current_resource_ptr = resource;
- if (!resource) {
- return (AE_NO_MEMORY);
- }
-
- /* Perform the AML-to-Resource conversion */
-
- status = acpi_ut_walk_aml_resources(aml_buffer, aml_buffer_length,
- acpi_rs_convert_aml_to_resources,
- ¤t_resource_ptr);
- if (status == AE_AML_NO_RESOURCE_END_TAG) {
- status = AE_OK;
- }
- if (ACPI_FAILURE(status)) {
- ACPI_FREE(resource);
- } else {
- *resource_ptr = resource;
- }
-
- return (status);
-}
-
/*******************************************************************************
*
* FUNCTION: acpi_rs_create_resource_list
@@ -130,10 +66,9 @@ acpi_buffer_to_resource(u8 *aml_buffer,
* of device resources.
*
******************************************************************************/
-
acpi_status
acpi_rs_create_resource_list(union acpi_operand_object *aml_buffer,
- struct acpi_buffer * output_buffer)
+ struct acpi_buffer *output_buffer)
{
acpi_status status;
diff --git a/trunk/drivers/acpi/acpica/rsdump.c b/trunk/drivers/acpi/acpica/rsdump.c
index b4c581132393..33db7520c74b 100644
--- a/trunk/drivers/acpi/acpica/rsdump.c
+++ b/trunk/drivers/acpi/acpica/rsdump.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -61,13 +61,11 @@ static void acpi_rs_out_integer64(char *title, u64 value);
static void acpi_rs_out_title(char *title);
-static void acpi_rs_dump_byte_list(u16 length, u8 *data);
+static void acpi_rs_dump_byte_list(u16 length, u8 * data);
-static void acpi_rs_dump_word_list(u16 length, u16 *data);
+static void acpi_rs_dump_dword_list(u8 length, u32 * data);
-static void acpi_rs_dump_dword_list(u8 length, u32 *data);
-
-static void acpi_rs_dump_short_byte_list(u8 length, u8 *data);
+static void acpi_rs_dump_short_byte_list(u8 length, u8 * data);
static void
acpi_rs_dump_resource_source(struct acpi_resource_source *resource_source);
@@ -311,125 +309,6 @@ struct acpi_rsdump_info acpi_rs_dump_generic_reg[6] = {
{ACPI_RSD_UINT64, ACPI_RSD_OFFSET(generic_reg.address), "Address", NULL}
};
-struct acpi_rsdump_info acpi_rs_dump_gpio[16] = {
- {ACPI_RSD_TITLE, ACPI_RSD_TABLE_SIZE(acpi_rs_dump_gpio), "GPIO", NULL},
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET(gpio.revision_id), "RevisionId", NULL},
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET(gpio.connection_type),
- "ConnectionType", acpi_gbl_ct_decode},
- {ACPI_RSD_1BITFLAG, ACPI_RSD_OFFSET(gpio.producer_consumer),
- "ProducerConsumer", acpi_gbl_consume_decode},
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET(gpio.pin_config), "PinConfig",
- acpi_gbl_ppc_decode},
- {ACPI_RSD_2BITFLAG, ACPI_RSD_OFFSET(gpio.sharable), "Sharable",
- acpi_gbl_shr_decode},
- {ACPI_RSD_2BITFLAG, ACPI_RSD_OFFSET(gpio.io_restriction),
- "IoRestriction", acpi_gbl_ior_decode},
- {ACPI_RSD_1BITFLAG, ACPI_RSD_OFFSET(gpio.triggering), "Triggering",
- acpi_gbl_he_decode},
- {ACPI_RSD_2BITFLAG, ACPI_RSD_OFFSET(gpio.polarity), "Polarity",
- acpi_gbl_ll_decode},
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET(gpio.drive_strength), "DriveStrength",
- NULL},
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET(gpio.debounce_timeout),
- "DebounceTimeout", NULL},
- {ACPI_RSD_SOURCE, ACPI_RSD_OFFSET(gpio.resource_source),
- "ResourceSource", NULL},
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET(gpio.pin_table_length),
- "PinTableLength", NULL},
- {ACPI_RSD_WORDLIST, ACPI_RSD_OFFSET(gpio.pin_table), "PinTable", NULL},
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET(gpio.vendor_length), "VendorLength",
- NULL},
- {ACPI_RSD_SHORTLISTX, ACPI_RSD_OFFSET(gpio.vendor_data), "VendorData",
- NULL},
-};
-
-struct acpi_rsdump_info acpi_rs_dump_fixed_dma[4] = {
- {ACPI_RSD_TITLE, ACPI_RSD_TABLE_SIZE(acpi_rs_dump_fixed_dma),
- "FixedDma", NULL},
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET(fixed_dma.request_lines),
- "RequestLines", NULL},
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET(fixed_dma.channels), "Channels",
- NULL},
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET(fixed_dma.width), "TransferWidth",
- acpi_gbl_dts_decode},
-};
-
-#define ACPI_RS_DUMP_COMMON_SERIAL_BUS \
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET (common_serial_bus.revision_id), "RevisionId", NULL}, \
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET (common_serial_bus.type), "Type", acpi_gbl_sbt_decode}, \
- {ACPI_RSD_1BITFLAG, ACPI_RSD_OFFSET (common_serial_bus.producer_consumer), "ProducerConsumer", acpi_gbl_consume_decode}, \
- {ACPI_RSD_1BITFLAG, ACPI_RSD_OFFSET (common_serial_bus.slave_mode), "SlaveMode", acpi_gbl_sm_decode}, \
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET (common_serial_bus.type_revision_id), "TypeRevisionId", NULL}, \
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET (common_serial_bus.type_data_length), "TypeDataLength", NULL}, \
- {ACPI_RSD_SOURCE, ACPI_RSD_OFFSET (common_serial_bus.resource_source), "ResourceSource", NULL}, \
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET (common_serial_bus.vendor_length), "VendorLength", NULL}, \
- {ACPI_RSD_SHORTLISTX,ACPI_RSD_OFFSET (common_serial_bus.vendor_data), "VendorData", NULL},
-
-struct acpi_rsdump_info acpi_rs_dump_common_serial_bus[10] = {
- {ACPI_RSD_TITLE, ACPI_RSD_TABLE_SIZE(acpi_rs_dump_common_serial_bus),
- "Common Serial Bus", NULL},
- ACPI_RS_DUMP_COMMON_SERIAL_BUS
-};
-
-struct acpi_rsdump_info acpi_rs_dump_i2c_serial_bus[13] = {
- {ACPI_RSD_TITLE, ACPI_RSD_TABLE_SIZE(acpi_rs_dump_i2c_serial_bus),
- "I2C Serial Bus", NULL},
- ACPI_RS_DUMP_COMMON_SERIAL_BUS {ACPI_RSD_1BITFLAG,
- ACPI_RSD_OFFSET(i2c_serial_bus.
- access_mode),
- "AccessMode", acpi_gbl_am_decode},
- {ACPI_RSD_UINT32, ACPI_RSD_OFFSET(i2c_serial_bus.connection_speed),
- "ConnectionSpeed", NULL},
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET(i2c_serial_bus.slave_address),
- "SlaveAddress", NULL},
-};
-
-struct acpi_rsdump_info acpi_rs_dump_spi_serial_bus[17] = {
- {ACPI_RSD_TITLE, ACPI_RSD_TABLE_SIZE(acpi_rs_dump_spi_serial_bus),
- "Spi Serial Bus", NULL},
- ACPI_RS_DUMP_COMMON_SERIAL_BUS {ACPI_RSD_1BITFLAG,
- ACPI_RSD_OFFSET(spi_serial_bus.
- wire_mode), "WireMode",
- acpi_gbl_wm_decode},
- {ACPI_RSD_1BITFLAG, ACPI_RSD_OFFSET(spi_serial_bus.device_polarity),
- "DevicePolarity", acpi_gbl_dp_decode},
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET(spi_serial_bus.data_bit_length),
- "DataBitLength", NULL},
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET(spi_serial_bus.clock_phase),
- "ClockPhase", acpi_gbl_cph_decode},
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET(spi_serial_bus.clock_polarity),
- "ClockPolarity", acpi_gbl_cpo_decode},
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET(spi_serial_bus.device_selection),
- "DeviceSelection", NULL},
- {ACPI_RSD_UINT32, ACPI_RSD_OFFSET(spi_serial_bus.connection_speed),
- "ConnectionSpeed", NULL},
-};
-
-struct acpi_rsdump_info acpi_rs_dump_uart_serial_bus[19] = {
- {ACPI_RSD_TITLE, ACPI_RSD_TABLE_SIZE(acpi_rs_dump_uart_serial_bus),
- "Uart Serial Bus", NULL},
- ACPI_RS_DUMP_COMMON_SERIAL_BUS {ACPI_RSD_2BITFLAG,
- ACPI_RSD_OFFSET(uart_serial_bus.
- flow_control),
- "FlowControl", acpi_gbl_fc_decode},
- {ACPI_RSD_2BITFLAG, ACPI_RSD_OFFSET(uart_serial_bus.stop_bits),
- "StopBits", acpi_gbl_sb_decode},
- {ACPI_RSD_3BITFLAG, ACPI_RSD_OFFSET(uart_serial_bus.data_bits),
- "DataBits", acpi_gbl_bpb_decode},
- {ACPI_RSD_1BITFLAG, ACPI_RSD_OFFSET(uart_serial_bus.endian), "Endian",
- acpi_gbl_ed_decode},
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET(uart_serial_bus.parity), "Parity",
- acpi_gbl_pt_decode},
- {ACPI_RSD_UINT8, ACPI_RSD_OFFSET(uart_serial_bus.lines_enabled),
- "LinesEnabled", NULL},
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET(uart_serial_bus.rx_fifo_size),
- "RxFifoSize", NULL},
- {ACPI_RSD_UINT16, ACPI_RSD_OFFSET(uart_serial_bus.tx_fifo_size),
- "TxFifoSize", NULL},
- {ACPI_RSD_UINT32, ACPI_RSD_OFFSET(uart_serial_bus.default_baud_rate),
- "ConnectionSpeed", NULL},
-};
-
/*
* Tables used for common address descriptor flag fields
*/
@@ -534,14 +413,7 @@ acpi_rs_dump_descriptor(void *resource, struct acpi_rsdump_info *table)
/* Data items, 8/16/32/64 bit */
case ACPI_RSD_UINT8:
- if (table->pointer) {
- acpi_rs_out_string(name, ACPI_CAST_PTR(char,
- table->
- pointer
- [*target]));
- } else {
- acpi_rs_out_integer8(name, ACPI_GET8(target));
- }
+ acpi_rs_out_integer8(name, ACPI_GET8(target));
break;
case ACPI_RSD_UINT16:
@@ -572,13 +444,6 @@ acpi_rs_dump_descriptor(void *resource, struct acpi_rsdump_info *table)
0x03]));
break;
- case ACPI_RSD_3BITFLAG:
- acpi_rs_out_string(name, ACPI_CAST_PTR(char,
- table->
- pointer[*target &
- 0x07]));
- break;
-
case ACPI_RSD_SHORTLIST:
/*
* Short byte list (single line output) for DMA and IRQ resources
@@ -591,20 +456,6 @@ acpi_rs_dump_descriptor(void *resource, struct acpi_rsdump_info *table)
}
break;
- case ACPI_RSD_SHORTLISTX:
- /*
- * Short byte list (single line output) for GPIO vendor data
- * Note: The list length is obtained from the previous table entry
- */
- if (previous_target) {
- acpi_rs_out_title(name);
- acpi_rs_dump_short_byte_list(*previous_target,
- *
- (ACPI_CAST_INDIRECT_PTR
- (u8, target)));
- }
- break;
-
case ACPI_RSD_LONGLIST:
/*
* Long byte list for Vendor resource data
@@ -629,18 +480,6 @@ acpi_rs_dump_descriptor(void *resource, struct acpi_rsdump_info *table)
}
break;
- case ACPI_RSD_WORDLIST:
- /*
- * Word list for GPIO Pin Table
- * Note: The list length is obtained from the previous table entry
- */
- if (previous_target) {
- acpi_rs_dump_word_list(*previous_target,
- *(ACPI_CAST_INDIRECT_PTR
- (u16, target)));
- }
- break;
-
case ACPI_RSD_ADDRESS:
/*
* Common flags for all Address resources
@@ -788,20 +627,14 @@ void acpi_rs_dump_resource_list(struct acpi_resource *resource_list)
/* Dump the resource descriptor */
- if (type == ACPI_RESOURCE_TYPE_SERIAL_BUS) {
- acpi_rs_dump_descriptor(&resource_list->data,
- acpi_gbl_dump_serial_bus_dispatch
- [resource_list->data.
- common_serial_bus.type]);
- } else {
- acpi_rs_dump_descriptor(&resource_list->data,
- acpi_gbl_dump_resource_dispatch
- [type]);
- }
+ acpi_rs_dump_descriptor(&resource_list->data,
+ acpi_gbl_dump_resource_dispatch[type]);
/* Point to the next resource structure */
- resource_list = ACPI_NEXT_RESOURCE(resource_list);
+ resource_list =
+ ACPI_ADD_PTR(struct acpi_resource, resource_list,
+ resource_list->length);
/* Exit when END_TAG descriptor is reached */
@@ -935,13 +768,4 @@ static void acpi_rs_dump_dword_list(u8 length, u32 * data)
}
}
-static void acpi_rs_dump_word_list(u16 length, u16 *data)
-{
- u16 i;
-
- for (i = 0; i < length; i++) {
- acpi_os_printf("%25s%2.2X : %4.4X\n", "Word", i, data[i]);
- }
-}
-
#endif
diff --git a/trunk/drivers/acpi/acpica/rsinfo.c b/trunk/drivers/acpi/acpica/rsinfo.c
index a9fa5158200b..f9ea60872aa4 100644
--- a/trunk/drivers/acpi/acpica/rsinfo.c
+++ b/trunk/drivers/acpi/acpica/rsinfo.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -76,10 +76,7 @@ struct acpi_rsconvert_info *acpi_gbl_set_resource_dispatch[] = {
acpi_rs_convert_address64, /* 0x0D, ACPI_RESOURCE_TYPE_ADDRESS64 */
acpi_rs_convert_ext_address64, /* 0x0E, ACPI_RESOURCE_TYPE_EXTENDED_ADDRESS64 */
acpi_rs_convert_ext_irq, /* 0x0F, ACPI_RESOURCE_TYPE_EXTENDED_IRQ */
- acpi_rs_convert_generic_reg, /* 0x10, ACPI_RESOURCE_TYPE_GENERIC_REGISTER */
- acpi_rs_convert_gpio, /* 0x11, ACPI_RESOURCE_TYPE_GPIO */
- acpi_rs_convert_fixed_dma, /* 0x12, ACPI_RESOURCE_TYPE_FIXED_DMA */
- NULL, /* 0x13, ACPI_RESOURCE_TYPE_SERIAL_BUS - Use subtype table below */
+ acpi_rs_convert_generic_reg /* 0x10, ACPI_RESOURCE_TYPE_GENERIC_REGISTER */
};
/* Dispatch tables for AML-to-resource (Get Resource) conversion functions */
@@ -97,7 +94,7 @@ struct acpi_rsconvert_info *acpi_gbl_get_resource_dispatch[] = {
acpi_rs_convert_end_dpf, /* 0x07, ACPI_RESOURCE_NAME_END_DEPENDENT */
acpi_rs_convert_io, /* 0x08, ACPI_RESOURCE_NAME_IO */
acpi_rs_convert_fixed_io, /* 0x09, ACPI_RESOURCE_NAME_FIXED_IO */
- acpi_rs_convert_fixed_dma, /* 0x0A, ACPI_RESOURCE_NAME_FIXED_DMA */
+ NULL, /* 0x0A, Reserved */
NULL, /* 0x0B, Reserved */
NULL, /* 0x0C, Reserved */
NULL, /* 0x0D, Reserved */
@@ -117,19 +114,7 @@ struct acpi_rsconvert_info *acpi_gbl_get_resource_dispatch[] = {
acpi_rs_convert_address16, /* 0x08, ACPI_RESOURCE_NAME_ADDRESS16 */
acpi_rs_convert_ext_irq, /* 0x09, ACPI_RESOURCE_NAME_EXTENDED_IRQ */
acpi_rs_convert_address64, /* 0x0A, ACPI_RESOURCE_NAME_ADDRESS64 */
- acpi_rs_convert_ext_address64, /* 0x0B, ACPI_RESOURCE_NAME_EXTENDED_ADDRESS64 */
- acpi_rs_convert_gpio, /* 0x0C, ACPI_RESOURCE_NAME_GPIO */
- NULL, /* 0x0D, Reserved */
- NULL, /* 0x0E, ACPI_RESOURCE_NAME_SERIAL_BUS - Use subtype table below */
-};
-
-/* Subtype table for serial_bus -- I2C, SPI, and UART */
-
-struct acpi_rsconvert_info *acpi_gbl_convert_resource_serial_bus_dispatch[] = {
- NULL,
- acpi_rs_convert_i2c_serial_bus,
- acpi_rs_convert_spi_serial_bus,
- acpi_rs_convert_uart_serial_bus,
+ acpi_rs_convert_ext_address64 /* 0x0B, ACPI_RESOURCE_NAME_EXTENDED_ADDRESS64 */
};
#ifdef ACPI_FUTURE_USAGE
@@ -155,16 +140,6 @@ struct acpi_rsdump_info *acpi_gbl_dump_resource_dispatch[] = {
acpi_rs_dump_ext_address64, /* ACPI_RESOURCE_TYPE_EXTENDED_ADDRESS64 */
acpi_rs_dump_ext_irq, /* ACPI_RESOURCE_TYPE_EXTENDED_IRQ */
acpi_rs_dump_generic_reg, /* ACPI_RESOURCE_TYPE_GENERIC_REGISTER */
- acpi_rs_dump_gpio, /* ACPI_RESOURCE_TYPE_GPIO */
- acpi_rs_dump_fixed_dma, /* ACPI_RESOURCE_TYPE_FIXED_DMA */
- NULL, /* ACPI_RESOURCE_TYPE_SERIAL_BUS */
-};
-
-struct acpi_rsdump_info *acpi_gbl_dump_serial_bus_dispatch[] = {
- NULL,
- acpi_rs_dump_i2c_serial_bus, /* AML_RESOURCE_I2C_BUS_TYPE */
- acpi_rs_dump_spi_serial_bus, /* AML_RESOURCE_SPI_BUS_TYPE */
- acpi_rs_dump_uart_serial_bus, /* AML_RESOURCE_UART_BUS_TYPE */
};
#endif
@@ -191,10 +166,7 @@ const u8 acpi_gbl_aml_resource_sizes[] = {
sizeof(struct aml_resource_address64), /* ACPI_RESOURCE_TYPE_ADDRESS64 */
sizeof(struct aml_resource_extended_address64), /*ACPI_RESOURCE_TYPE_EXTENDED_ADDRESS64 */
sizeof(struct aml_resource_extended_irq), /* ACPI_RESOURCE_TYPE_EXTENDED_IRQ */
- sizeof(struct aml_resource_generic_register), /* ACPI_RESOURCE_TYPE_GENERIC_REGISTER */
- sizeof(struct aml_resource_gpio), /* ACPI_RESOURCE_TYPE_GPIO */
- sizeof(struct aml_resource_fixed_dma), /* ACPI_RESOURCE_TYPE_FIXED_DMA */
- sizeof(struct aml_resource_common_serialbus), /* ACPI_RESOURCE_TYPE_SERIAL_BUS */
+ sizeof(struct aml_resource_generic_register) /* ACPI_RESOURCE_TYPE_GENERIC_REGISTER */
};
const u8 acpi_gbl_resource_struct_sizes[] = {
@@ -210,7 +182,7 @@ const u8 acpi_gbl_resource_struct_sizes[] = {
ACPI_RS_SIZE_MIN,
ACPI_RS_SIZE(struct acpi_resource_io),
ACPI_RS_SIZE(struct acpi_resource_fixed_io),
- ACPI_RS_SIZE(struct acpi_resource_fixed_dma),
+ 0,
0,
0,
0,
@@ -230,21 +202,5 @@ const u8 acpi_gbl_resource_struct_sizes[] = {
ACPI_RS_SIZE(struct acpi_resource_address16),
ACPI_RS_SIZE(struct acpi_resource_extended_irq),
ACPI_RS_SIZE(struct acpi_resource_address64),
- ACPI_RS_SIZE(struct acpi_resource_extended_address64),
- ACPI_RS_SIZE(struct acpi_resource_gpio),
- ACPI_RS_SIZE(struct acpi_resource_common_serialbus)
-};
-
-const u8 acpi_gbl_aml_resource_serial_bus_sizes[] = {
- 0,
- sizeof(struct aml_resource_i2c_serialbus),
- sizeof(struct aml_resource_spi_serialbus),
- sizeof(struct aml_resource_uart_serialbus),
-};
-
-const u8 acpi_gbl_resource_struct_serial_bus_sizes[] = {
- 0,
- ACPI_RS_SIZE(struct acpi_resource_i2c_serialbus),
- ACPI_RS_SIZE(struct acpi_resource_spi_serialbus),
- ACPI_RS_SIZE(struct acpi_resource_uart_serialbus),
+ ACPI_RS_SIZE(struct acpi_resource_extended_address64)
};
diff --git a/trunk/drivers/acpi/acpica/rsio.c b/trunk/drivers/acpi/acpica/rsio.c
index f6a081057a22..0c7efef008be 100644
--- a/trunk/drivers/acpi/acpica/rsio.c
+++ b/trunk/drivers/acpi/acpica/rsio.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/rsirq.c b/trunk/drivers/acpi/acpica/rsirq.c
index e23a9ec248cb..50b8ad211167 100644
--- a/trunk/drivers/acpi/acpica/rsirq.c
+++ b/trunk/drivers/acpi/acpica/rsirq.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -264,34 +264,3 @@ struct acpi_rsconvert_info acpi_rs_convert_dma[6] = {
AML_OFFSET(dma.dma_channel_mask),
ACPI_RS_OFFSET(data.dma.channel_count)}
};
-
-/*******************************************************************************
- *
- * acpi_rs_convert_fixed_dma
- *
- ******************************************************************************/
-
-struct acpi_rsconvert_info acpi_rs_convert_fixed_dma[4] = {
- {ACPI_RSC_INITGET, ACPI_RESOURCE_TYPE_FIXED_DMA,
- ACPI_RS_SIZE(struct acpi_resource_fixed_dma),
- ACPI_RSC_TABLE_SIZE(acpi_rs_convert_fixed_dma)},
-
- {ACPI_RSC_INITSET, ACPI_RESOURCE_NAME_FIXED_DMA,
- sizeof(struct aml_resource_fixed_dma),
- 0},
-
- /*
- * These fields are contiguous in both the source and destination:
- * request_lines
- * Channels
- */
-
- {ACPI_RSC_MOVE16, ACPI_RS_OFFSET(data.fixed_dma.request_lines),
- AML_OFFSET(fixed_dma.request_lines),
- 2},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.fixed_dma.width),
- AML_OFFSET(fixed_dma.width),
- 1},
-
-};
diff --git a/trunk/drivers/acpi/acpica/rslist.c b/trunk/drivers/acpi/acpica/rslist.c
index 9be129f5d6f4..1bfcef736c50 100644
--- a/trunk/drivers/acpi/acpica/rslist.c
+++ b/trunk/drivers/acpi/acpica/rslist.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -70,8 +70,6 @@ acpi_rs_convert_aml_to_resources(u8 * aml,
struct acpi_resource **resource_ptr =
ACPI_CAST_INDIRECT_PTR(struct acpi_resource, context);
struct acpi_resource *resource;
- union aml_resource *aml_resource;
- struct acpi_rsconvert_info *conversion_table;
acpi_status status;
ACPI_FUNCTION_TRACE(rs_convert_aml_to_resources);
@@ -86,37 +84,14 @@ acpi_rs_convert_aml_to_resources(u8 * aml,
"Misaligned resource pointer %p", resource));
}
- /* Get the appropriate conversion info table */
-
- aml_resource = ACPI_CAST_PTR(union aml_resource, aml);
- if (acpi_ut_get_resource_type(aml) == ACPI_RESOURCE_NAME_SERIAL_BUS) {
- if (aml_resource->common_serial_bus.type >
- AML_RESOURCE_MAX_SERIALBUSTYPE) {
- conversion_table = NULL;
- } else {
- /* This is an I2C, SPI, or UART serial_bus descriptor */
-
- conversion_table =
- acpi_gbl_convert_resource_serial_bus_dispatch
- [aml_resource->common_serial_bus.type];
- }
- } else {
- conversion_table =
- acpi_gbl_get_resource_dispatch[resource_index];
- }
-
- if (!conversion_table) {
- ACPI_ERROR((AE_INFO,
- "Invalid/unsupported resource descriptor: Type 0x%2.2X",
- resource_index));
- return (AE_AML_INVALID_RESOURCE_TYPE);
- }
-
/* Convert the AML byte stream resource to a local resource struct */
status =
- acpi_rs_convert_aml_to_resource(resource, aml_resource,
- conversion_table);
+ acpi_rs_convert_aml_to_resource(resource,
+ ACPI_CAST_PTR(union aml_resource,
+ aml),
+ acpi_gbl_get_resource_dispatch
+ [resource_index]);
if (ACPI_FAILURE(status)) {
ACPI_EXCEPTION((AE_INFO, status,
"Could not convert AML resource (Type 0x%X)",
@@ -131,7 +106,7 @@ acpi_rs_convert_aml_to_resources(u8 * aml,
/* Point to the next structure in the output buffer */
- *resource_ptr = ACPI_NEXT_RESOURCE(resource);
+ *resource_ptr = ACPI_ADD_PTR(void, resource, resource->length);
return_ACPI_STATUS(AE_OK);
}
@@ -160,7 +135,6 @@ acpi_rs_convert_resources_to_aml(struct acpi_resource *resource,
{
u8 *aml = output_buffer;
u8 *end_aml = output_buffer + aml_size_needed;
- struct acpi_rsconvert_info *conversion_table;
acpi_status status;
ACPI_FUNCTION_TRACE(rs_convert_resources_to_aml);
@@ -180,34 +154,11 @@ acpi_rs_convert_resources_to_aml(struct acpi_resource *resource,
/* Perform the conversion */
- if (resource->type == ACPI_RESOURCE_TYPE_SERIAL_BUS) {
- if (resource->data.common_serial_bus.type >
- AML_RESOURCE_MAX_SERIALBUSTYPE) {
- conversion_table = NULL;
- } else {
- /* This is an I2C, SPI, or UART serial_bus descriptor */
-
- conversion_table =
- acpi_gbl_convert_resource_serial_bus_dispatch
- [resource->data.common_serial_bus.type];
- }
- } else {
- conversion_table =
- acpi_gbl_set_resource_dispatch[resource->type];
- }
-
- if (!conversion_table) {
- ACPI_ERROR((AE_INFO,
- "Invalid/unsupported resource descriptor: Type 0x%2.2X",
- resource->type));
- return (AE_AML_INVALID_RESOURCE_TYPE);
- }
-
- status = acpi_rs_convert_resource_to_aml(resource,
- ACPI_CAST_PTR(union
- aml_resource,
- aml),
- conversion_table);
+ status = acpi_rs_convert_resource_to_aml(resource, ACPI_CAST_PTR(union
+ aml_resource,
+ aml),
+ acpi_gbl_set_resource_dispatch
+ [resource->type]);
if (ACPI_FAILURE(status)) {
ACPI_EXCEPTION((AE_INFO, status,
"Could not convert resource (type 0x%X) to AML",
@@ -241,7 +192,9 @@ acpi_rs_convert_resources_to_aml(struct acpi_resource *resource,
/* Point to the next input resource descriptor */
- resource = ACPI_NEXT_RESOURCE(resource);
+ resource =
+ ACPI_ADD_PTR(struct acpi_resource, resource,
+ resource->length);
}
/* Completed buffer, but did not find an end_tag resource descriptor */
diff --git a/trunk/drivers/acpi/acpica/rsmemory.c b/trunk/drivers/acpi/acpica/rsmemory.c
index 4fd611ad02b4..7cc6d8625f1e 100644
--- a/trunk/drivers/acpi/acpica/rsmemory.c
+++ b/trunk/drivers/acpi/acpica/rsmemory.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/rsmisc.c b/trunk/drivers/acpi/acpica/rsmisc.c
index 8073b371cc7c..410264b22a29 100644
--- a/trunk/drivers/acpi/acpica/rsmisc.c
+++ b/trunk/drivers/acpi/acpica/rsmisc.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -83,10 +83,6 @@ acpi_rs_convert_aml_to_resource(struct acpi_resource *resource,
ACPI_FUNCTION_TRACE(rs_convert_aml_to_resource);
- if (!info) {
- return_ACPI_STATUS(AE_BAD_PARAMETER);
- }
-
if (((acpi_size) resource) & 0x3) {
/* Each internal resource struct is expected to be 32-bit aligned */
@@ -105,6 +101,7 @@ acpi_rs_convert_aml_to_resource(struct acpi_resource *resource,
* table length (# of table entries)
*/
count = INIT_TABLE_LENGTH(info);
+
while (count) {
/*
* Source is the external AML byte stream buffer,
@@ -148,14 +145,6 @@ acpi_rs_convert_aml_to_resource(struct acpi_resource *resource,
((ACPI_GET8(source) >> info->value) & 0x03);
break;
- case ACPI_RSC_3BITFLAG:
- /*
- * Mask and shift the flag bits
- */
- ACPI_SET8(destination) = (u8)
- ((ACPI_GET8(source) >> info->value) & 0x07);
- break;
-
case ACPI_RSC_COUNT:
item_count = ACPI_GET8(source);
@@ -174,69 +163,6 @@ acpi_rs_convert_aml_to_resource(struct acpi_resource *resource,
(info->value * (item_count - 1));
break;
- case ACPI_RSC_COUNT_GPIO_PIN:
-
- target = ACPI_ADD_PTR(void, aml, info->value);
- item_count = ACPI_GET16(target) - ACPI_GET16(source);
-
- resource->length = resource->length + item_count;
- item_count = item_count / 2;
- ACPI_SET16(destination) = item_count;
- break;
-
- case ACPI_RSC_COUNT_GPIO_VEN:
-
- item_count = ACPI_GET8(source);
- ACPI_SET8(destination) = (u8)item_count;
-
- resource->length = resource->length +
- (info->value * item_count);
- break;
-
- case ACPI_RSC_COUNT_GPIO_RES:
-
- /*
- * Vendor data is optional (length/offset may both be zero)
- * Examine vendor data length field first
- */
- target = ACPI_ADD_PTR(void, aml, (info->value + 2));
- if (ACPI_GET16(target)) {
-
- /* Use vendor offset to get resource source length */
-
- target = ACPI_ADD_PTR(void, aml, info->value);
- item_count =
- ACPI_GET16(target) - ACPI_GET16(source);
- } else {
- /* No vendor data to worry about */
-
- item_count = aml->large_header.resource_length +
- sizeof(struct aml_resource_large_header) -
- ACPI_GET16(source);
- }
-
- resource->length = resource->length + item_count;
- ACPI_SET16(destination) = item_count;
- break;
-
- case ACPI_RSC_COUNT_SERIAL_VEN:
-
- item_count = ACPI_GET16(source) - info->value;
-
- resource->length = resource->length + item_count;
- ACPI_SET16(destination) = item_count;
- break;
-
- case ACPI_RSC_COUNT_SERIAL_RES:
-
- item_count = (aml_resource_length +
- sizeof(struct aml_resource_large_header))
- - ACPI_GET16(source) - info->value;
-
- resource->length = resource->length + item_count;
- ACPI_SET16(destination) = item_count;
- break;
-
case ACPI_RSC_LENGTH:
resource->length = resource->length + info->value;
@@ -257,72 +183,6 @@ acpi_rs_convert_aml_to_resource(struct acpi_resource *resource,
info->opcode);
break;
- case ACPI_RSC_MOVE_GPIO_PIN:
-
- /* Generate and set the PIN data pointer */
-
- target = (char *)ACPI_ADD_PTR(void, resource,
- (resource->length -
- item_count * 2));
- *(u16 **)destination = ACPI_CAST_PTR(u16, target);
-
- /* Copy the PIN data */
-
- source = ACPI_ADD_PTR(void, aml, ACPI_GET16(source));
- acpi_rs_move_data(target, source, item_count,
- info->opcode);
- break;
-
- case ACPI_RSC_MOVE_GPIO_RES:
-
- /* Generate and set the resource_source string pointer */
-
- target = (char *)ACPI_ADD_PTR(void, resource,
- (resource->length -
- item_count));
- *(u8 **)destination = ACPI_CAST_PTR(u8, target);
-
- /* Copy the resource_source string */
-
- source = ACPI_ADD_PTR(void, aml, ACPI_GET16(source));
- acpi_rs_move_data(target, source, item_count,
- info->opcode);
- break;
-
- case ACPI_RSC_MOVE_SERIAL_VEN:
-
- /* Generate and set the Vendor Data pointer */
-
- target = (char *)ACPI_ADD_PTR(void, resource,
- (resource->length -
- item_count));
- *(u8 **)destination = ACPI_CAST_PTR(u8, target);
-
- /* Copy the Vendor Data */
-
- source = ACPI_ADD_PTR(void, aml, info->value);
- acpi_rs_move_data(target, source, item_count,
- info->opcode);
- break;
-
- case ACPI_RSC_MOVE_SERIAL_RES:
-
- /* Generate and set the resource_source string pointer */
-
- target = (char *)ACPI_ADD_PTR(void, resource,
- (resource->length -
- item_count));
- *(u8 **)destination = ACPI_CAST_PTR(u8, target);
-
- /* Copy the resource_source string */
-
- source =
- ACPI_ADD_PTR(void, aml,
- (ACPI_GET16(source) + info->value));
- acpi_rs_move_data(target, source, item_count,
- info->opcode);
- break;
-
case ACPI_RSC_SET8:
ACPI_MEMSET(destination, info->aml_offset, info->value);
@@ -359,18 +219,13 @@ acpi_rs_convert_aml_to_resource(struct acpi_resource *resource,
* Optional resource_source (Index and String). This is the more
* complicated case used by the Interrupt() macro
*/
- target = ACPI_ADD_PTR(char, resource,
- info->aml_offset +
- (item_count * 4));
+ target =
+ ACPI_ADD_PTR(char, resource,
+ info->aml_offset + (item_count * 4));
resource->length +=
acpi_rs_get_resource_source(aml_resource_length,
- (acpi_rs_length)
- (((item_count -
- 1) * sizeof(u32)) +
- info->value),
- destination, aml,
- target);
+ (acpi_rs_length) (((item_count - 1) * sizeof(u32)) + info->value), destination, aml, target);
break;
case ACPI_RSC_BITMASK:
@@ -472,7 +327,6 @@ acpi_rs_convert_resource_to_aml(struct acpi_resource *resource,
{
void *source = NULL;
void *destination;
- char *target;
acpi_rsdesc_size aml_length = 0;
u8 count;
u16 temp16 = 0;
@@ -480,10 +334,6 @@ acpi_rs_convert_resource_to_aml(struct acpi_resource *resource,
ACPI_FUNCTION_TRACE(rs_convert_resource_to_aml);
- if (!info) {
- return_ACPI_STATUS(AE_BAD_PARAMETER);
- }
-
/*
* First table entry must be ACPI_RSC_INITxxx and must contain the
* table length (# of table entries)
@@ -533,14 +383,6 @@ acpi_rs_convert_resource_to_aml(struct acpi_resource *resource,
((ACPI_GET8(source) & 0x03) << info->value);
break;
- case ACPI_RSC_3BITFLAG:
- /*
- * Mask and shift the flag bits
- */
- ACPI_SET8(destination) |= (u8)
- ((ACPI_GET8(source) & 0x07) << info->value);
- break;
-
case ACPI_RSC_COUNT:
item_count = ACPI_GET8(source);
@@ -558,63 +400,6 @@ acpi_rs_convert_resource_to_aml(struct acpi_resource *resource,
acpi_rs_set_resource_length(aml_length, aml);
break;
- case ACPI_RSC_COUNT_GPIO_PIN:
-
- item_count = ACPI_GET16(source);
- ACPI_SET16(destination) = (u16)aml_length;
-
- aml_length = (u16)(aml_length + item_count * 2);
- target = ACPI_ADD_PTR(void, aml, info->value);
- ACPI_SET16(target) = (u16)aml_length;
- acpi_rs_set_resource_length(aml_length, aml);
- break;
-
- case ACPI_RSC_COUNT_GPIO_VEN:
-
- item_count = ACPI_GET16(source);
- ACPI_SET16(destination) = (u16)item_count;
-
- aml_length =
- (u16)(aml_length + (info->value * item_count));
- acpi_rs_set_resource_length(aml_length, aml);
- break;
-
- case ACPI_RSC_COUNT_GPIO_RES:
-
- /* Set resource source string length */
-
- item_count = ACPI_GET16(source);
- ACPI_SET16(destination) = (u16)aml_length;
-
- /* Compute offset for the Vendor Data */
-
- aml_length = (u16)(aml_length + item_count);
- target = ACPI_ADD_PTR(void, aml, info->value);
-
- /* Set vendor offset only if there is vendor data */
-
- if (resource->data.gpio.vendor_length) {
- ACPI_SET16(target) = (u16)aml_length;
- }
-
- acpi_rs_set_resource_length(aml_length, aml);
- break;
-
- case ACPI_RSC_COUNT_SERIAL_VEN:
-
- item_count = ACPI_GET16(source);
- ACPI_SET16(destination) = item_count + info->value;
- aml_length = (u16)(aml_length + item_count);
- acpi_rs_set_resource_length(aml_length, aml);
- break;
-
- case ACPI_RSC_COUNT_SERIAL_RES:
-
- item_count = ACPI_GET16(source);
- aml_length = (u16)(aml_length + item_count);
- acpi_rs_set_resource_length(aml_length, aml);
- break;
-
case ACPI_RSC_LENGTH:
acpi_rs_set_resource_length(info->value, aml);
@@ -632,48 +417,6 @@ acpi_rs_convert_resource_to_aml(struct acpi_resource *resource,
info->opcode);
break;
- case ACPI_RSC_MOVE_GPIO_PIN:
-
- destination = (char *)ACPI_ADD_PTR(void, aml,
- ACPI_GET16
- (destination));
- source = *(u16 **)source;
- acpi_rs_move_data(destination, source, item_count,
- info->opcode);
- break;
-
- case ACPI_RSC_MOVE_GPIO_RES:
-
- /* Used for both resource_source string and vendor_data */
-
- destination = (char *)ACPI_ADD_PTR(void, aml,
- ACPI_GET16
- (destination));
- source = *(u8 **)source;
- acpi_rs_move_data(destination, source, item_count,
- info->opcode);
- break;
-
- case ACPI_RSC_MOVE_SERIAL_VEN:
-
- destination = (char *)ACPI_ADD_PTR(void, aml,
- (aml_length -
- item_count));
- source = *(u8 **)source;
- acpi_rs_move_data(destination, source, item_count,
- info->opcode);
- break;
-
- case ACPI_RSC_MOVE_SERIAL_RES:
-
- destination = (char *)ACPI_ADD_PTR(void, aml,
- (aml_length -
- item_count));
- source = *(u8 **)source;
- acpi_rs_move_data(destination, source, item_count,
- info->opcode);
- break;
-
case ACPI_RSC_ADDRESS:
/* Set the Resource Type, General Flags, and Type-Specific Flags */
diff --git a/trunk/drivers/acpi/acpica/rsserial.c b/trunk/drivers/acpi/acpica/rsserial.c
deleted file mode 100644
index 9aa5e689b444..000000000000
--- a/trunk/drivers/acpi/acpica/rsserial.c
+++ /dev/null
@@ -1,441 +0,0 @@
-/*******************************************************************************
- *
- * Module Name: rsserial - GPIO/serial_bus resource descriptors
- *
- ******************************************************************************/
-
-/*
- * Copyright (C) 2000 - 2012, Intel Corp.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions, and the following disclaimer,
- * without modification.
- * 2. Redistributions in binary form must reproduce at minimum a disclaimer
- * substantially similar to the "NO WARRANTY" disclaimer below
- * ("Disclaimer") and any redistribution must be conditioned upon
- * including a substantially similar Disclaimer requirement for further
- * binary redistribution.
- * 3. Neither the names of the above-listed copyright holders nor the names
- * of any contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * Alternatively, this software may be distributed under the terms of the
- * GNU General Public License ("GPL") version 2 as published by the Free
- * Software Foundation.
- *
- * NO WARRANTY
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
- * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGES.
- */
-
-#include
-#include "accommon.h"
-#include "acresrc.h"
-
-#define _COMPONENT ACPI_RESOURCES
-ACPI_MODULE_NAME("rsserial")
-
-/*******************************************************************************
- *
- * acpi_rs_convert_gpio
- *
- ******************************************************************************/
-struct acpi_rsconvert_info acpi_rs_convert_gpio[17] = {
- {ACPI_RSC_INITGET, ACPI_RESOURCE_TYPE_GPIO,
- ACPI_RS_SIZE(struct acpi_resource_gpio),
- ACPI_RSC_TABLE_SIZE(acpi_rs_convert_gpio)},
-
- {ACPI_RSC_INITSET, ACPI_RESOURCE_NAME_GPIO,
- sizeof(struct aml_resource_gpio),
- 0},
-
- /*
- * These fields are contiguous in both the source and destination:
- * revision_id
- * connection_type
- */
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.gpio.revision_id),
- AML_OFFSET(gpio.revision_id),
- 2},
-
- {ACPI_RSC_1BITFLAG, ACPI_RS_OFFSET(data.gpio.producer_consumer),
- AML_OFFSET(gpio.flags),
- 0},
-
- {ACPI_RSC_2BITFLAG, ACPI_RS_OFFSET(data.gpio.sharable),
- AML_OFFSET(gpio.int_flags),
- 3},
-
- {ACPI_RSC_2BITFLAG, ACPI_RS_OFFSET(data.gpio.io_restriction),
- AML_OFFSET(gpio.int_flags),
- 0},
-
- {ACPI_RSC_1BITFLAG, ACPI_RS_OFFSET(data.gpio.triggering),
- AML_OFFSET(gpio.int_flags),
- 0},
-
- {ACPI_RSC_2BITFLAG, ACPI_RS_OFFSET(data.gpio.polarity),
- AML_OFFSET(gpio.int_flags),
- 1},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.gpio.pin_config),
- AML_OFFSET(gpio.pin_config),
- 1},
-
- /*
- * These fields are contiguous in both the source and destination:
- * drive_strength
- * debounce_timeout
- */
- {ACPI_RSC_MOVE16, ACPI_RS_OFFSET(data.gpio.drive_strength),
- AML_OFFSET(gpio.drive_strength),
- 2},
-
- /* Pin Table */
-
- {ACPI_RSC_COUNT_GPIO_PIN, ACPI_RS_OFFSET(data.gpio.pin_table_length),
- AML_OFFSET(gpio.pin_table_offset),
- AML_OFFSET(gpio.res_source_offset)},
-
- {ACPI_RSC_MOVE_GPIO_PIN, ACPI_RS_OFFSET(data.gpio.pin_table),
- AML_OFFSET(gpio.pin_table_offset),
- 0},
-
- /* Resource Source */
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.gpio.resource_source.index),
- AML_OFFSET(gpio.res_source_index),
- 1},
-
- {ACPI_RSC_COUNT_GPIO_RES,
- ACPI_RS_OFFSET(data.gpio.resource_source.string_length),
- AML_OFFSET(gpio.res_source_offset),
- AML_OFFSET(gpio.vendor_offset)},
-
- {ACPI_RSC_MOVE_GPIO_RES,
- ACPI_RS_OFFSET(data.gpio.resource_source.string_ptr),
- AML_OFFSET(gpio.res_source_offset),
- 0},
-
- /* Vendor Data */
-
- {ACPI_RSC_COUNT_GPIO_VEN, ACPI_RS_OFFSET(data.gpio.vendor_length),
- AML_OFFSET(gpio.vendor_length),
- 1},
-
- {ACPI_RSC_MOVE_GPIO_RES, ACPI_RS_OFFSET(data.gpio.vendor_data),
- AML_OFFSET(gpio.vendor_offset),
- 0},
-};
-
-/*******************************************************************************
- *
- * acpi_rs_convert_i2c_serial_bus
- *
- ******************************************************************************/
-
-struct acpi_rsconvert_info acpi_rs_convert_i2c_serial_bus[16] = {
- {ACPI_RSC_INITGET, ACPI_RESOURCE_TYPE_SERIAL_BUS,
- ACPI_RS_SIZE(struct acpi_resource_i2c_serialbus),
- ACPI_RSC_TABLE_SIZE(acpi_rs_convert_i2c_serial_bus)},
-
- {ACPI_RSC_INITSET, ACPI_RESOURCE_NAME_SERIAL_BUS,
- sizeof(struct aml_resource_i2c_serialbus),
- 0},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.common_serial_bus.revision_id),
- AML_OFFSET(common_serial_bus.revision_id),
- 1},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.common_serial_bus.type),
- AML_OFFSET(common_serial_bus.type),
- 1},
-
- {ACPI_RSC_1BITFLAG, ACPI_RS_OFFSET(data.common_serial_bus.slave_mode),
- AML_OFFSET(common_serial_bus.flags),
- 0},
-
- {ACPI_RSC_1BITFLAG,
- ACPI_RS_OFFSET(data.common_serial_bus.producer_consumer),
- AML_OFFSET(common_serial_bus.flags),
- 1},
-
- {ACPI_RSC_MOVE8,
- ACPI_RS_OFFSET(data.common_serial_bus.type_revision_id),
- AML_OFFSET(common_serial_bus.type_revision_id),
- 1},
-
- {ACPI_RSC_MOVE16,
- ACPI_RS_OFFSET(data.common_serial_bus.type_data_length),
- AML_OFFSET(common_serial_bus.type_data_length),
- 1},
-
- /* Vendor data */
-
- {ACPI_RSC_COUNT_SERIAL_VEN,
- ACPI_RS_OFFSET(data.common_serial_bus.vendor_length),
- AML_OFFSET(common_serial_bus.type_data_length),
- AML_RESOURCE_I2C_MIN_DATA_LEN},
-
- {ACPI_RSC_MOVE_SERIAL_VEN,
- ACPI_RS_OFFSET(data.common_serial_bus.vendor_data),
- 0,
- sizeof(struct aml_resource_i2c_serialbus)},
-
- /* Resource Source */
-
- {ACPI_RSC_MOVE8,
- ACPI_RS_OFFSET(data.common_serial_bus.resource_source.index),
- AML_OFFSET(common_serial_bus.res_source_index),
- 1},
-
- {ACPI_RSC_COUNT_SERIAL_RES,
- ACPI_RS_OFFSET(data.common_serial_bus.resource_source.string_length),
- AML_OFFSET(common_serial_bus.type_data_length),
- sizeof(struct aml_resource_common_serialbus)},
-
- {ACPI_RSC_MOVE_SERIAL_RES,
- ACPI_RS_OFFSET(data.common_serial_bus.resource_source.string_ptr),
- AML_OFFSET(common_serial_bus.type_data_length),
- sizeof(struct aml_resource_common_serialbus)},
-
- /* I2C bus type specific */
-
- {ACPI_RSC_1BITFLAG, ACPI_RS_OFFSET(data.i2c_serial_bus.access_mode),
- AML_OFFSET(i2c_serial_bus.type_specific_flags),
- 0},
-
- {ACPI_RSC_MOVE32, ACPI_RS_OFFSET(data.i2c_serial_bus.connection_speed),
- AML_OFFSET(i2c_serial_bus.connection_speed),
- 1},
-
- {ACPI_RSC_MOVE16, ACPI_RS_OFFSET(data.i2c_serial_bus.slave_address),
- AML_OFFSET(i2c_serial_bus.slave_address),
- 1},
-};
-
-/*******************************************************************************
- *
- * acpi_rs_convert_spi_serial_bus
- *
- ******************************************************************************/
-
-struct acpi_rsconvert_info acpi_rs_convert_spi_serial_bus[20] = {
- {ACPI_RSC_INITGET, ACPI_RESOURCE_TYPE_SERIAL_BUS,
- ACPI_RS_SIZE(struct acpi_resource_spi_serialbus),
- ACPI_RSC_TABLE_SIZE(acpi_rs_convert_spi_serial_bus)},
-
- {ACPI_RSC_INITSET, ACPI_RESOURCE_NAME_SERIAL_BUS,
- sizeof(struct aml_resource_spi_serialbus),
- 0},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.common_serial_bus.revision_id),
- AML_OFFSET(common_serial_bus.revision_id),
- 1},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.common_serial_bus.type),
- AML_OFFSET(common_serial_bus.type),
- 1},
-
- {ACPI_RSC_1BITFLAG, ACPI_RS_OFFSET(data.common_serial_bus.slave_mode),
- AML_OFFSET(common_serial_bus.flags),
- 0},
-
- {ACPI_RSC_1BITFLAG,
- ACPI_RS_OFFSET(data.common_serial_bus.producer_consumer),
- AML_OFFSET(common_serial_bus.flags),
- 1},
-
- {ACPI_RSC_MOVE8,
- ACPI_RS_OFFSET(data.common_serial_bus.type_revision_id),
- AML_OFFSET(common_serial_bus.type_revision_id),
- 1},
-
- {ACPI_RSC_MOVE16,
- ACPI_RS_OFFSET(data.common_serial_bus.type_data_length),
- AML_OFFSET(common_serial_bus.type_data_length),
- 1},
-
- /* Vendor data */
-
- {ACPI_RSC_COUNT_SERIAL_VEN,
- ACPI_RS_OFFSET(data.common_serial_bus.vendor_length),
- AML_OFFSET(common_serial_bus.type_data_length),
- AML_RESOURCE_SPI_MIN_DATA_LEN},
-
- {ACPI_RSC_MOVE_SERIAL_VEN,
- ACPI_RS_OFFSET(data.common_serial_bus.vendor_data),
- 0,
- sizeof(struct aml_resource_spi_serialbus)},
-
- /* Resource Source */
-
- {ACPI_RSC_MOVE8,
- ACPI_RS_OFFSET(data.common_serial_bus.resource_source.index),
- AML_OFFSET(common_serial_bus.res_source_index),
- 1},
-
- {ACPI_RSC_COUNT_SERIAL_RES,
- ACPI_RS_OFFSET(data.common_serial_bus.resource_source.string_length),
- AML_OFFSET(common_serial_bus.type_data_length),
- sizeof(struct aml_resource_common_serialbus)},
-
- {ACPI_RSC_MOVE_SERIAL_RES,
- ACPI_RS_OFFSET(data.common_serial_bus.resource_source.string_ptr),
- AML_OFFSET(common_serial_bus.type_data_length),
- sizeof(struct aml_resource_common_serialbus)},
-
- /* Spi bus type specific */
-
- {ACPI_RSC_1BITFLAG, ACPI_RS_OFFSET(data.spi_serial_bus.wire_mode),
- AML_OFFSET(spi_serial_bus.type_specific_flags),
- 0},
-
- {ACPI_RSC_1BITFLAG, ACPI_RS_OFFSET(data.spi_serial_bus.device_polarity),
- AML_OFFSET(spi_serial_bus.type_specific_flags),
- 1},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.spi_serial_bus.data_bit_length),
- AML_OFFSET(spi_serial_bus.data_bit_length),
- 1},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.spi_serial_bus.clock_phase),
- AML_OFFSET(spi_serial_bus.clock_phase),
- 1},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.spi_serial_bus.clock_polarity),
- AML_OFFSET(spi_serial_bus.clock_polarity),
- 1},
-
- {ACPI_RSC_MOVE16, ACPI_RS_OFFSET(data.spi_serial_bus.device_selection),
- AML_OFFSET(spi_serial_bus.device_selection),
- 1},
-
- {ACPI_RSC_MOVE32, ACPI_RS_OFFSET(data.spi_serial_bus.connection_speed),
- AML_OFFSET(spi_serial_bus.connection_speed),
- 1},
-};
-
-/*******************************************************************************
- *
- * acpi_rs_convert_uart_serial_bus
- *
- ******************************************************************************/
-
-struct acpi_rsconvert_info acpi_rs_convert_uart_serial_bus[22] = {
- {ACPI_RSC_INITGET, ACPI_RESOURCE_TYPE_SERIAL_BUS,
- ACPI_RS_SIZE(struct acpi_resource_uart_serialbus),
- ACPI_RSC_TABLE_SIZE(acpi_rs_convert_uart_serial_bus)},
-
- {ACPI_RSC_INITSET, ACPI_RESOURCE_NAME_SERIAL_BUS,
- sizeof(struct aml_resource_uart_serialbus),
- 0},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.common_serial_bus.revision_id),
- AML_OFFSET(common_serial_bus.revision_id),
- 1},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.common_serial_bus.type),
- AML_OFFSET(common_serial_bus.type),
- 1},
-
- {ACPI_RSC_1BITFLAG, ACPI_RS_OFFSET(data.common_serial_bus.slave_mode),
- AML_OFFSET(common_serial_bus.flags),
- 0},
-
- {ACPI_RSC_1BITFLAG,
- ACPI_RS_OFFSET(data.common_serial_bus.producer_consumer),
- AML_OFFSET(common_serial_bus.flags),
- 1},
-
- {ACPI_RSC_MOVE8,
- ACPI_RS_OFFSET(data.common_serial_bus.type_revision_id),
- AML_OFFSET(common_serial_bus.type_revision_id),
- 1},
-
- {ACPI_RSC_MOVE16,
- ACPI_RS_OFFSET(data.common_serial_bus.type_data_length),
- AML_OFFSET(common_serial_bus.type_data_length),
- 1},
-
- /* Vendor data */
-
- {ACPI_RSC_COUNT_SERIAL_VEN,
- ACPI_RS_OFFSET(data.common_serial_bus.vendor_length),
- AML_OFFSET(common_serial_bus.type_data_length),
- AML_RESOURCE_UART_MIN_DATA_LEN},
-
- {ACPI_RSC_MOVE_SERIAL_VEN,
- ACPI_RS_OFFSET(data.common_serial_bus.vendor_data),
- 0,
- sizeof(struct aml_resource_uart_serialbus)},
-
- /* Resource Source */
-
- {ACPI_RSC_MOVE8,
- ACPI_RS_OFFSET(data.common_serial_bus.resource_source.index),
- AML_OFFSET(common_serial_bus.res_source_index),
- 1},
-
- {ACPI_RSC_COUNT_SERIAL_RES,
- ACPI_RS_OFFSET(data.common_serial_bus.resource_source.string_length),
- AML_OFFSET(common_serial_bus.type_data_length),
- sizeof(struct aml_resource_common_serialbus)},
-
- {ACPI_RSC_MOVE_SERIAL_RES,
- ACPI_RS_OFFSET(data.common_serial_bus.resource_source.string_ptr),
- AML_OFFSET(common_serial_bus.type_data_length),
- sizeof(struct aml_resource_common_serialbus)},
-
- /* Uart bus type specific */
-
- {ACPI_RSC_2BITFLAG, ACPI_RS_OFFSET(data.uart_serial_bus.flow_control),
- AML_OFFSET(uart_serial_bus.type_specific_flags),
- 0},
-
- {ACPI_RSC_2BITFLAG, ACPI_RS_OFFSET(data.uart_serial_bus.stop_bits),
- AML_OFFSET(uart_serial_bus.type_specific_flags),
- 2},
-
- {ACPI_RSC_3BITFLAG, ACPI_RS_OFFSET(data.uart_serial_bus.data_bits),
- AML_OFFSET(uart_serial_bus.type_specific_flags),
- 4},
-
- {ACPI_RSC_1BITFLAG, ACPI_RS_OFFSET(data.uart_serial_bus.endian),
- AML_OFFSET(uart_serial_bus.type_specific_flags),
- 7},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.uart_serial_bus.parity),
- AML_OFFSET(uart_serial_bus.parity),
- 1},
-
- {ACPI_RSC_MOVE8, ACPI_RS_OFFSET(data.uart_serial_bus.lines_enabled),
- AML_OFFSET(uart_serial_bus.lines_enabled),
- 1},
-
- {ACPI_RSC_MOVE16, ACPI_RS_OFFSET(data.uart_serial_bus.rx_fifo_size),
- AML_OFFSET(uart_serial_bus.rx_fifo_size),
- 1},
-
- {ACPI_RSC_MOVE16, ACPI_RS_OFFSET(data.uart_serial_bus.tx_fifo_size),
- AML_OFFSET(uart_serial_bus.tx_fifo_size),
- 1},
-
- {ACPI_RSC_MOVE32,
- ACPI_RS_OFFSET(data.uart_serial_bus.default_baud_rate),
- AML_OFFSET(uart_serial_bus.default_baud_rate),
- 1},
-};
diff --git a/trunk/drivers/acpi/acpica/rsutils.c b/trunk/drivers/acpi/acpica/rsutils.c
index 433a375deb93..231811e56939 100644
--- a/trunk/drivers/acpi/acpica/rsutils.c
+++ b/trunk/drivers/acpi/acpica/rsutils.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -144,9 +144,6 @@ acpi_rs_move_data(void *destination, void *source, u16 item_count, u8 move_type)
* since there are no alignment or endian issues
*/
case ACPI_RSC_MOVE8:
- case ACPI_RSC_MOVE_GPIO_RES:
- case ACPI_RSC_MOVE_SERIAL_VEN:
- case ACPI_RSC_MOVE_SERIAL_RES:
ACPI_MEMCPY(destination, source, item_count);
return;
@@ -156,7 +153,6 @@ acpi_rs_move_data(void *destination, void *source, u16 item_count, u8 move_type)
* misaligned memory transfers
*/
case ACPI_RSC_MOVE16:
- case ACPI_RSC_MOVE_GPIO_PIN:
ACPI_MOVE_16_TO_16(&ACPI_CAST_PTR(u16, destination)[i],
&ACPI_CAST_PTR(u16, source)[i]);
break;
@@ -592,56 +588,6 @@ acpi_rs_get_prs_method_data(struct acpi_namespace_node *node,
}
#endif /* ACPI_FUTURE_USAGE */
-/*******************************************************************************
- *
- * FUNCTION: acpi_rs_get_aei_method_data
- *
- * PARAMETERS: Node - Device node
- * ret_buffer - Pointer to a buffer structure for the
- * results
- *
- * RETURN: Status
- *
- * DESCRIPTION: This function is called to get the _AEI value of an object
- * contained in an object specified by the handle passed in
- *
- * If the function fails an appropriate status will be returned
- * and the contents of the callers buffer is undefined.
- *
- ******************************************************************************/
-
-acpi_status
-acpi_rs_get_aei_method_data(struct acpi_namespace_node *node,
- struct acpi_buffer *ret_buffer)
-{
- union acpi_operand_object *obj_desc;
- acpi_status status;
-
- ACPI_FUNCTION_TRACE(rs_get_aei_method_data);
-
- /* Parameters guaranteed valid by caller */
-
- /* Execute the method, no parameters */
-
- status = acpi_ut_evaluate_object(node, METHOD_NAME__AEI,
- ACPI_BTYPE_BUFFER, &obj_desc);
- if (ACPI_FAILURE(status)) {
- return_ACPI_STATUS(status);
- }
-
- /*
- * Make the call to create a resource linked list from the
- * byte stream buffer that comes back from the _CRS method
- * execution.
- */
- status = acpi_rs_create_resource_list(obj_desc, ret_buffer);
-
- /* On exit, we must delete the object returned by evaluate_object */
-
- acpi_ut_remove_reference(obj_desc);
- return_ACPI_STATUS(status);
-}
-
/*******************************************************************************
*
* FUNCTION: acpi_rs_get_method_data
diff --git a/trunk/drivers/acpi/acpica/rsxface.c b/trunk/drivers/acpi/acpica/rsxface.c
index f58c098c7aeb..fe86b37b16ce 100644
--- a/trunk/drivers/acpi/acpica/rsxface.c
+++ b/trunk/drivers/acpi/acpica/rsxface.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -307,46 +307,6 @@ acpi_set_current_resources(acpi_handle device_handle,
ACPI_EXPORT_SYMBOL(acpi_set_current_resources)
-/*******************************************************************************
- *
- * FUNCTION: acpi_get_event_resources
- *
- * PARAMETERS: device_handle - Handle to the device object for the
- * device we are getting resources
- * in_buffer - Pointer to a buffer containing the
- * resources to be set for the device
- *
- * RETURN: Status
- *
- * DESCRIPTION: This function is called to get the event resources for a
- * specific device. The caller must first acquire a handle for
- * the desired device. The resource data is passed to the routine
- * the buffer pointed to by the in_buffer variable. Uses the
- * _AEI method.
- *
- ******************************************************************************/
-acpi_status
-acpi_get_event_resources(acpi_handle device_handle,
- struct acpi_buffer *ret_buffer)
-{
- acpi_status status;
- struct acpi_namespace_node *node;
-
- ACPI_FUNCTION_TRACE(acpi_get_event_resources);
-
- /* Validate parameters then dispatch to internal routine */
-
- status = acpi_rs_validate_parameters(device_handle, ret_buffer, &node);
- if (ACPI_FAILURE(status)) {
- return_ACPI_STATUS(status);
- }
-
- status = acpi_rs_get_aei_method_data(node, ret_buffer);
- return_ACPI_STATUS(status);
-}
-
-ACPI_EXPORT_SYMBOL(acpi_get_event_resources)
-
/******************************************************************************
*
* FUNCTION: acpi_resource_to_address64
@@ -526,9 +486,8 @@ acpi_rs_match_vendor_resource(struct acpi_resource *resource, void *context)
*
* PARAMETERS: device_handle - Handle to the device object for the
* device we are querying
- * Name - Method name of the resources we want.
- * (METHOD_NAME__CRS, METHOD_NAME__PRS, or
- * METHOD_NAME__AEI)
+ * Name - Method name of the resources we want
+ * (METHOD_NAME__CRS or METHOD_NAME__PRS)
* user_function - Called for each resource
* Context - Passed to user_function
*
@@ -555,12 +514,11 @@ acpi_walk_resources(acpi_handle device_handle,
if (!device_handle || !user_function || !name ||
(!ACPI_COMPARE_NAME(name, METHOD_NAME__CRS) &&
- !ACPI_COMPARE_NAME(name, METHOD_NAME__PRS) &&
- !ACPI_COMPARE_NAME(name, METHOD_NAME__AEI))) {
+ !ACPI_COMPARE_NAME(name, METHOD_NAME__PRS))) {
return_ACPI_STATUS(AE_BAD_PARAMETER);
}
- /* Get the _CRS/_PRS/_AEI resource list */
+ /* Get the _CRS or _PRS resource list */
buffer.length = ACPI_ALLOCATE_LOCAL_BUFFER;
status = acpi_rs_get_method_data(device_handle, name, &buffer);
diff --git a/trunk/drivers/acpi/acpica/tbfadt.c b/trunk/drivers/acpi/acpica/tbfadt.c
index c5d870406f41..6f5588e62c0a 100644
--- a/trunk/drivers/acpi/acpica/tbfadt.c
+++ b/trunk/drivers/acpi/acpica/tbfadt.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -63,15 +63,14 @@ static void acpi_tb_setup_fadt_registers(void);
typedef struct acpi_fadt_info {
char *name;
- u16 address64;
- u16 address32;
- u16 length;
+ u8 address64;
+ u8 address32;
+ u8 length;
u8 default_length;
u8 type;
} acpi_fadt_info;
-#define ACPI_FADT_OPTIONAL 0
#define ACPI_FADT_REQUIRED 1
#define ACPI_FADT_SEPARATE_LENGTH 2
@@ -88,7 +87,7 @@ static struct acpi_fadt_info fadt_info_table[] = {
ACPI_FADT_OFFSET(pm1b_event_block),
ACPI_FADT_OFFSET(pm1_event_length),
ACPI_PM1_REGISTER_WIDTH * 2, /* Enable + Status register */
- ACPI_FADT_OPTIONAL},
+ 0},
{"Pm1aControlBlock",
ACPI_FADT_OFFSET(xpm1a_control_block),
@@ -102,7 +101,7 @@ static struct acpi_fadt_info fadt_info_table[] = {
ACPI_FADT_OFFSET(pm1b_control_block),
ACPI_FADT_OFFSET(pm1_control_length),
ACPI_PM1_REGISTER_WIDTH,
- ACPI_FADT_OPTIONAL},
+ 0},
{"Pm2ControlBlock",
ACPI_FADT_OFFSET(xpm2_control_block),
@@ -140,7 +139,7 @@ static struct acpi_fadt_info fadt_info_table[] = {
typedef struct acpi_fadt_pm_info {
struct acpi_generic_address *target;
- u16 source;
+ u8 source;
u8 register_num;
} acpi_fadt_pm_info;
@@ -254,13 +253,8 @@ void acpi_tb_parse_fadt(u32 table_index)
acpi_tb_install_table((acpi_physical_address) acpi_gbl_FADT.Xdsdt,
ACPI_SIG_DSDT, ACPI_TABLE_INDEX_DSDT);
- /* If Hardware Reduced flag is set, there is no FACS */
-
- if (!acpi_gbl_reduced_hardware) {
- acpi_tb_install_table((acpi_physical_address) acpi_gbl_FADT.
- Xfacs, ACPI_SIG_FACS,
- ACPI_TABLE_INDEX_FACS);
- }
+ acpi_tb_install_table((acpi_physical_address) acpi_gbl_FADT.Xfacs,
+ ACPI_SIG_FACS, ACPI_TABLE_INDEX_FACS);
}
/*******************************************************************************
@@ -283,12 +277,12 @@ void acpi_tb_create_local_fadt(struct acpi_table_header *table, u32 length)
{
/*
* Check if the FADT is larger than the largest table that we expect
- * (the ACPI 5.0 version). If so, truncate the table, and issue
+ * (the ACPI 2.0/3.0 version). If so, truncate the table, and issue
* a warning.
*/
if (length > sizeof(struct acpi_table_fadt)) {
ACPI_WARNING((AE_INFO,
- "FADT (revision %u) is longer than ACPI 5.0 version, "
+ "FADT (revision %u) is longer than ACPI 2.0 version, "
"truncating length %u to %u",
table->revision, length,
(u32)sizeof(struct acpi_table_fadt)));
@@ -303,13 +297,6 @@ void acpi_tb_create_local_fadt(struct acpi_table_header *table, u32 length)
ACPI_MEMCPY(&acpi_gbl_FADT, table,
ACPI_MIN(length, sizeof(struct acpi_table_fadt)));
- /* Take a copy of the Hardware Reduced flag */
-
- acpi_gbl_reduced_hardware = FALSE;
- if (acpi_gbl_FADT.flags & ACPI_FADT_HW_REDUCED) {
- acpi_gbl_reduced_hardware = TRUE;
- }
-
/* Convert the local copy of the FADT to the common internal format */
acpi_tb_convert_fadt();
@@ -515,12 +502,6 @@ static void acpi_tb_validate_fadt(void)
acpi_gbl_FADT.Xdsdt = (u64) acpi_gbl_FADT.dsdt;
}
- /* If Hardware Reduced flag is set, we are all done */
-
- if (acpi_gbl_reduced_hardware) {
- return;
- }
-
/* Examine all of the 64-bit extended address fields (X fields) */
for (i = 0; i < ACPI_FADT_INFO_ENTRIES; i++) {
diff --git a/trunk/drivers/acpi/acpica/tbfind.c b/trunk/drivers/acpi/acpica/tbfind.c
index 4903e36ea75a..a55cb2bb5abb 100644
--- a/trunk/drivers/acpi/acpica/tbfind.c
+++ b/trunk/drivers/acpi/acpica/tbfind.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/tbinstal.c b/trunk/drivers/acpi/acpica/tbinstal.c
index 1aecf7baa4e0..62365f6075dd 100644
--- a/trunk/drivers/acpi/acpica/tbinstal.c
+++ b/trunk/drivers/acpi/acpica/tbinstal.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/tbutils.c b/trunk/drivers/acpi/acpica/tbutils.c
index 09ca39e14337..0f2d395feaba 100644
--- a/trunk/drivers/acpi/acpica/tbutils.c
+++ b/trunk/drivers/acpi/acpica/tbutils.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -135,13 +135,6 @@ acpi_status acpi_tb_initialize_facs(void)
{
acpi_status status;
- /* If Hardware Reduced flag is set, there is no FACS */
-
- if (acpi_gbl_reduced_hardware) {
- acpi_gbl_FACS = NULL;
- return (AE_OK);
- }
-
status = acpi_get_table_by_index(ACPI_TABLE_INDEX_FACS,
ACPI_CAST_INDIRECT_PTR(struct
acpi_table_header,
diff --git a/trunk/drivers/acpi/acpica/tbxface.c b/trunk/drivers/acpi/acpica/tbxface.c
index abcc6412c244..e7d13f5d3f2d 100644
--- a/trunk/drivers/acpi/acpica/tbxface.c
+++ b/trunk/drivers/acpi/acpica/tbxface.c
@@ -6,7 +6,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/tbxfroot.c b/trunk/drivers/acpi/acpica/tbxfroot.c
index 4258f647ca3d..7eb6c6cc1edf 100644
--- a/trunk/drivers/acpi/acpica/tbxfroot.c
+++ b/trunk/drivers/acpi/acpica/tbxfroot.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utaddress.c b/trunk/drivers/acpi/acpica/utaddress.c
deleted file mode 100644
index 67932aebe6dd..000000000000
--- a/trunk/drivers/acpi/acpica/utaddress.c
+++ /dev/null
@@ -1,294 +0,0 @@
-/******************************************************************************
- *
- * Module Name: utaddress - op_region address range check
- *
- *****************************************************************************/
-
-/*
- * Copyright (C) 2000 - 2012, Intel Corp.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions, and the following disclaimer,
- * without modification.
- * 2. Redistributions in binary form must reproduce at minimum a disclaimer
- * substantially similar to the "NO WARRANTY" disclaimer below
- * ("Disclaimer") and any redistribution must be conditioned upon
- * including a substantially similar Disclaimer requirement for further
- * binary redistribution.
- * 3. Neither the names of the above-listed copyright holders nor the names
- * of any contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * Alternatively, this software may be distributed under the terms of the
- * GNU General Public License ("GPL") version 2 as published by the Free
- * Software Foundation.
- *
- * NO WARRANTY
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
- * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGES.
- */
-
-#include
-#include "accommon.h"
-#include "acnamesp.h"
-
-#define _COMPONENT ACPI_UTILITIES
-ACPI_MODULE_NAME("utaddress")
-
-/*******************************************************************************
- *
- * FUNCTION: acpi_ut_add_address_range
- *
- * PARAMETERS: space_id - Address space ID
- * Address - op_region start address
- * Length - op_region length
- * region_node - op_region namespace node
- *
- * RETURN: Status
- *
- * DESCRIPTION: Add the Operation Region address range to the global list.
- * The only supported Space IDs are Memory and I/O. Called when
- * the op_region address/length operands are fully evaluated.
- *
- * MUTEX: Locks the namespace
- *
- * NOTE: Because this interface is only called when an op_region argument
- * list is evaluated, there cannot be any duplicate region_nodes.
- * Duplicate Address/Length values are allowed, however, so that multiple
- * address conflicts can be detected.
- *
- ******************************************************************************/
-acpi_status
-acpi_ut_add_address_range(acpi_adr_space_type space_id,
- acpi_physical_address address,
- u32 length, struct acpi_namespace_node *region_node)
-{
- struct acpi_address_range *range_info;
- acpi_status status;
-
- ACPI_FUNCTION_TRACE(ut_add_address_range);
-
- if ((space_id != ACPI_ADR_SPACE_SYSTEM_MEMORY) &&
- (space_id != ACPI_ADR_SPACE_SYSTEM_IO)) {
- return_ACPI_STATUS(AE_OK);
- }
-
- /* Allocate/init a new info block, add it to the appropriate list */
-
- range_info = ACPI_ALLOCATE(sizeof(struct acpi_address_range));
- if (!range_info) {
- return_ACPI_STATUS(AE_NO_MEMORY);
- }
-
- range_info->start_address = address;
- range_info->end_address = (address + length - 1);
- range_info->region_node = region_node;
-
- status = acpi_ut_acquire_mutex(ACPI_MTX_NAMESPACE);
- if (ACPI_FAILURE(status)) {
- ACPI_FREE(range_info);
- return_ACPI_STATUS(status);
- }
-
- range_info->next = acpi_gbl_address_range_list[space_id];
- acpi_gbl_address_range_list[space_id] = range_info;
-
- ACPI_DEBUG_PRINT((ACPI_DB_NAMES,
- "\nAdded [%4.4s] address range: 0x%p-0x%p\n",
- acpi_ut_get_node_name(range_info->region_node),
- ACPI_CAST_PTR(void, address),
- ACPI_CAST_PTR(void, range_info->end_address)));
-
- (void)acpi_ut_release_mutex(ACPI_MTX_NAMESPACE);
- return_ACPI_STATUS(AE_OK);
-}
-
-/*******************************************************************************
- *
- * FUNCTION: acpi_ut_remove_address_range
- *
- * PARAMETERS: space_id - Address space ID
- * region_node - op_region namespace node
- *
- * RETURN: None
- *
- * DESCRIPTION: Remove the Operation Region from the global list. The only
- * supported Space IDs are Memory and I/O. Called when an
- * op_region is deleted.
- *
- * MUTEX: Assumes the namespace is locked
- *
- ******************************************************************************/
-
-void
-acpi_ut_remove_address_range(acpi_adr_space_type space_id,
- struct acpi_namespace_node *region_node)
-{
- struct acpi_address_range *range_info;
- struct acpi_address_range *prev;
-
- ACPI_FUNCTION_TRACE(ut_remove_address_range);
-
- if ((space_id != ACPI_ADR_SPACE_SYSTEM_MEMORY) &&
- (space_id != ACPI_ADR_SPACE_SYSTEM_IO)) {
- return_VOID;
- }
-
- /* Get the appropriate list head and check the list */
-
- range_info = prev = acpi_gbl_address_range_list[space_id];
- while (range_info) {
- if (range_info->region_node == region_node) {
- if (range_info == prev) { /* Found at list head */
- acpi_gbl_address_range_list[space_id] =
- range_info->next;
- } else {
- prev->next = range_info->next;
- }
-
- ACPI_DEBUG_PRINT((ACPI_DB_NAMES,
- "\nRemoved [%4.4s] address range: 0x%p-0x%p\n",
- acpi_ut_get_node_name(range_info->
- region_node),
- ACPI_CAST_PTR(void,
- range_info->
- start_address),
- ACPI_CAST_PTR(void,
- range_info->
- end_address)));
-
- ACPI_FREE(range_info);
- return_VOID;
- }
-
- prev = range_info;
- range_info = range_info->next;
- }
-
- return_VOID;
-}
-
-/*******************************************************************************
- *
- * FUNCTION: acpi_ut_check_address_range
- *
- * PARAMETERS: space_id - Address space ID
- * Address - Start address
- * Length - Length of address range
- * Warn - TRUE if warning on overlap desired
- *
- * RETURN: Count of the number of conflicts detected. Zero is always
- * returned for Space IDs other than Memory or I/O.
- *
- * DESCRIPTION: Check if the input address range overlaps any of the
- * ASL operation region address ranges. The only supported
- * Space IDs are Memory and I/O.
- *
- * MUTEX: Assumes the namespace is locked.
- *
- ******************************************************************************/
-
-u32
-acpi_ut_check_address_range(acpi_adr_space_type space_id,
- acpi_physical_address address, u32 length, u8 warn)
-{
- struct acpi_address_range *range_info;
- acpi_physical_address end_address;
- char *pathname;
- u32 overlap_count = 0;
-
- ACPI_FUNCTION_TRACE(ut_check_address_range);
-
- if ((space_id != ACPI_ADR_SPACE_SYSTEM_MEMORY) &&
- (space_id != ACPI_ADR_SPACE_SYSTEM_IO)) {
- return_UINT32(0);
- }
-
- range_info = acpi_gbl_address_range_list[space_id];
- end_address = address + length - 1;
-
- /* Check entire list for all possible conflicts */
-
- while (range_info) {
- /*
- * Check if the requested Address/Length overlaps this address_range.
- * Four cases to consider:
- *
- * 1) Input address/length is contained completely in the address range
- * 2) Input address/length overlaps range at the range start
- * 3) Input address/length overlaps range at the range end
- * 4) Input address/length completely encompasses the range
- */
- if ((address <= range_info->end_address) &&
- (end_address >= range_info->start_address)) {
-
- /* Found an address range overlap */
-
- overlap_count++;
- if (warn) { /* Optional warning message */
- pathname =
- acpi_ns_get_external_pathname(range_info->
- region_node);
-
- ACPI_WARNING((AE_INFO,
- "0x%p-0x%p %s conflicts with Region %s %d",
- ACPI_CAST_PTR(void, address),
- ACPI_CAST_PTR(void, end_address),
- acpi_ut_get_region_name(space_id),
- pathname, overlap_count));
- ACPI_FREE(pathname);
- }
- }
-
- range_info = range_info->next;
- }
-
- return_UINT32(overlap_count);
-}
-
-/*******************************************************************************
- *
- * FUNCTION: acpi_ut_delete_address_lists
- *
- * PARAMETERS: None
- *
- * RETURN: None
- *
- * DESCRIPTION: Delete all global address range lists (called during
- * subsystem shutdown).
- *
- ******************************************************************************/
-
-void acpi_ut_delete_address_lists(void)
-{
- struct acpi_address_range *next;
- struct acpi_address_range *range_info;
- int i;
-
- /* Delete all elements in all address range lists */
-
- for (i = 0; i < ACPI_ADDRESS_RANGE_MAX; i++) {
- next = acpi_gbl_address_range_list[i];
-
- while (next) {
- range_info = next;
- next = range_info->next;
- ACPI_FREE(range_info);
- }
-
- acpi_gbl_address_range_list[i] = NULL;
- }
-}
diff --git a/trunk/drivers/acpi/acpica/utalloc.c b/trunk/drivers/acpi/acpica/utalloc.c
index 9982d2ea66fb..0a697351cf69 100644
--- a/trunk/drivers/acpi/acpica/utalloc.c
+++ b/trunk/drivers/acpi/acpica/utalloc.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utcopy.c b/trunk/drivers/acpi/acpica/utcopy.c
index 3317c0a406ee..aded299a2fa8 100644
--- a/trunk/drivers/acpi/acpica/utcopy.c
+++ b/trunk/drivers/acpi/acpica/utcopy.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utdebug.c b/trunk/drivers/acpi/acpica/utdebug.c
index a0998a886318..a1f8d7509e66 100644
--- a/trunk/drivers/acpi/acpica/utdebug.c
+++ b/trunk/drivers/acpi/acpica/utdebug.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utdecode.c b/trunk/drivers/acpi/acpica/utdecode.c
index d42ede5260c7..8b087e2d64f4 100644
--- a/trunk/drivers/acpi/acpica/utdecode.c
+++ b/trunk/drivers/acpi/acpica/utdecode.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -171,9 +171,7 @@ const char *acpi_gbl_region_types[ACPI_NUM_PREDEFINED_REGIONS] = {
"SMBus",
"SystemCMOS",
"PCIBARTarget",
- "IPMI",
- "GeneralPurposeIo",
- "GenericSerialBus"
+ "IPMI"
};
char *acpi_ut_get_region_name(u8 space_id)
diff --git a/trunk/drivers/acpi/acpica/utdelete.c b/trunk/drivers/acpi/acpica/utdelete.c
index 2a6c3e183697..31f5a7832ef1 100644
--- a/trunk/drivers/acpi/acpica/utdelete.c
+++ b/trunk/drivers/acpi/acpica/utdelete.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -215,14 +215,11 @@ static void acpi_ut_delete_internal_obj(union acpi_operand_object *object)
ACPI_DEBUG_PRINT((ACPI_DB_ALLOCATIONS,
"***** Region %p\n", object));
- /*
- * Update address_range list. However, only permanent regions
- * are installed in this list. (Not created within a method)
- */
- if (!(object->region.node->flags & ANOBJ_TEMPORARY)) {
- acpi_ut_remove_address_range(object->region.space_id,
- object->region.node);
- }
+ /* Invalidate the region address/length via the host OS */
+
+ acpi_os_invalidate_address(object->region.space_id,
+ object->region.address,
+ (acpi_size) object->region.length);
second_desc = acpi_ns_get_secondary_object(object);
if (second_desc) {
diff --git a/trunk/drivers/acpi/acpica/uteval.c b/trunk/drivers/acpi/acpica/uteval.c
index 479f32b33415..18f73c9d10bc 100644
--- a/trunk/drivers/acpi/acpica/uteval.c
+++ b/trunk/drivers/acpi/acpica/uteval.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utglobal.c b/trunk/drivers/acpi/acpica/utglobal.c
index 4153584cf526..ffba0a39c3e8 100644
--- a/trunk/drivers/acpi/acpica/utglobal.c
+++ b/trunk/drivers/acpi/acpica/utglobal.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -264,12 +264,6 @@ acpi_status acpi_ut_init_globals(void)
return_ACPI_STATUS(status);
}
- /* Address Range lists */
-
- for (i = 0; i < ACPI_ADDRESS_RANGE_MAX; i++) {
- acpi_gbl_address_range_list[i] = NULL;
- }
-
/* Mutex locked flags */
for (i = 0; i < ACPI_NUM_MUTEX; i++) {
diff --git a/trunk/drivers/acpi/acpica/utids.c b/trunk/drivers/acpi/acpica/utids.c
index c92eb1d93785..b679ea693545 100644
--- a/trunk/drivers/acpi/acpica/utids.c
+++ b/trunk/drivers/acpi/acpica/utids.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utinit.c b/trunk/drivers/acpi/acpica/utinit.c
index 8359c0c5dc98..191b6828cce9 100644
--- a/trunk/drivers/acpi/acpica/utinit.c
+++ b/trunk/drivers/acpi/acpica/utinit.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -92,7 +92,6 @@ static void acpi_ut_terminate(void)
gpe_xrupt_info = next_gpe_xrupt_info;
}
- acpi_ut_delete_address_lists();
return_VOID;
}
diff --git a/trunk/drivers/acpi/acpica/utlock.c b/trunk/drivers/acpi/acpica/utlock.c
index 155fd786d0f2..f6bb75c6faf5 100644
--- a/trunk/drivers/acpi/acpica/utlock.c
+++ b/trunk/drivers/acpi/acpica/utlock.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utmath.c b/trunk/drivers/acpi/acpica/utmath.c
index 2491a552b0e6..ce481da9bb45 100644
--- a/trunk/drivers/acpi/acpica/utmath.c
+++ b/trunk/drivers/acpi/acpica/utmath.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utmisc.c b/trunk/drivers/acpi/acpica/utmisc.c
index 86f19db74e05..c33a852d4f42 100644
--- a/trunk/drivers/acpi/acpica/utmisc.c
+++ b/trunk/drivers/acpi/acpica/utmisc.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utmutex.c b/trunk/drivers/acpi/acpica/utmutex.c
index 43174df33121..7d797e2baecd 100644
--- a/trunk/drivers/acpi/acpica/utmutex.c
+++ b/trunk/drivers/acpi/acpica/utmutex.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -293,10 +293,14 @@ acpi_status acpi_ut_acquire_mutex(acpi_mutex_handle mutex_id)
acpi_status acpi_ut_release_mutex(acpi_mutex_handle mutex_id)
{
+ acpi_thread_id this_thread_id;
+
ACPI_FUNCTION_NAME(ut_release_mutex);
+ this_thread_id = acpi_os_get_thread_id();
+
ACPI_DEBUG_PRINT((ACPI_DB_MUTEX, "Thread %u releasing Mutex [%s]\n",
- (u32)acpi_os_get_thread_id(),
+ (u32)this_thread_id,
acpi_ut_get_mutex_name(mutex_id)));
if (mutex_id > ACPI_MAX_MUTEX) {
@@ -325,8 +329,7 @@ acpi_status acpi_ut_release_mutex(acpi_mutex_handle mutex_id)
* the ACPI subsystem code.
*/
for (i = mutex_id; i < ACPI_NUM_MUTEX; i++) {
- if (acpi_gbl_mutex_info[i].thread_id ==
- acpi_os_get_thread_id()) {
+ if (acpi_gbl_mutex_info[i].thread_id == this_thread_id) {
if (i == mutex_id) {
continue;
}
diff --git a/trunk/drivers/acpi/acpica/utobject.c b/trunk/drivers/acpi/acpica/utobject.c
index b112744fc9ae..188340a017b4 100644
--- a/trunk/drivers/acpi/acpica/utobject.c
+++ b/trunk/drivers/acpi/acpica/utobject.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utosi.c b/trunk/drivers/acpi/acpica/utosi.c
index 2360cf70c18c..1fb10cb8f11d 100644
--- a/trunk/drivers/acpi/acpica/utosi.c
+++ b/trunk/drivers/acpi/acpica/utosi.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utresrc.c b/trunk/drivers/acpi/acpica/utresrc.c
index 9d441ea70305..6ffd3a8bdaa5 100644
--- a/trunk/drivers/acpi/acpica/utresrc.c
+++ b/trunk/drivers/acpi/acpica/utresrc.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -43,7 +43,7 @@
#include
#include "accommon.h"
-#include "acresrc.h"
+#include "amlresrc.h"
#define _COMPONENT ACPI_UTILITIES
ACPI_MODULE_NAME("utresrc")
@@ -154,138 +154,6 @@ const char *acpi_gbl_typ_decode[] = {
"TypeF"
};
-const char *acpi_gbl_ppc_decode[] = {
- "PullDefault",
- "PullUp",
- "PullDown",
- "PullNone"
-};
-
-const char *acpi_gbl_ior_decode[] = {
- "IoRestrictionNone",
- "IoRestrictionInputOnly",
- "IoRestrictionOutputOnly",
- "IoRestrictionNoneAndPreserve"
-};
-
-const char *acpi_gbl_dts_decode[] = {
- "Width8bit",
- "Width16bit",
- "Width32bit",
- "Width64bit",
- "Width128bit",
- "Width256bit",
-};
-
-/* GPIO connection type */
-
-const char *acpi_gbl_ct_decode[] = {
- "Interrupt",
- "I/O"
-};
-
-/* Serial bus type */
-
-const char *acpi_gbl_sbt_decode[] = {
- "/* UNKNOWN serial bus type */",
- "I2C",
- "SPI",
- "UART"
-};
-
-/* I2C serial bus access mode */
-
-const char *acpi_gbl_am_decode[] = {
- "AddressingMode7Bit",
- "AddressingMode10Bit"
-};
-
-/* I2C serial bus slave mode */
-
-const char *acpi_gbl_sm_decode[] = {
- "ControllerInitiated",
- "DeviceInitiated"
-};
-
-/* SPI serial bus wire mode */
-
-const char *acpi_gbl_wm_decode[] = {
- "FourWireMode",
- "ThreeWireMode"
-};
-
-/* SPI serial clock phase */
-
-const char *acpi_gbl_cph_decode[] = {
- "ClockPhaseFirst",
- "ClockPhaseSecond"
-};
-
-/* SPI serial bus clock polarity */
-
-const char *acpi_gbl_cpo_decode[] = {
- "ClockPolarityLow",
- "ClockPolarityHigh"
-};
-
-/* SPI serial bus device polarity */
-
-const char *acpi_gbl_dp_decode[] = {
- "PolarityLow",
- "PolarityHigh"
-};
-
-/* UART serial bus endian */
-
-const char *acpi_gbl_ed_decode[] = {
- "LittleEndian",
- "BigEndian"
-};
-
-/* UART serial bus bits per byte */
-
-const char *acpi_gbl_bpb_decode[] = {
- "DataBitsFive",
- "DataBitsSix",
- "DataBitsSeven",
- "DataBitsEight",
- "DataBitsNine",
- "/* UNKNOWN Bits per byte */",
- "/* UNKNOWN Bits per byte */",
- "/* UNKNOWN Bits per byte */"
-};
-
-/* UART serial bus stop bits */
-
-const char *acpi_gbl_sb_decode[] = {
- "StopBitsNone",
- "StopBitsOne",
- "StopBitsOnePlusHalf",
- "StopBitsTwo"
-};
-
-/* UART serial bus flow control */
-
-const char *acpi_gbl_fc_decode[] = {
- "FlowControlNone",
- "FlowControlHardware",
- "FlowControlXON",
- "/* UNKNOWN flow control keyword */"
-};
-
-/* UART serial bus parity type */
-
-const char *acpi_gbl_pt_decode[] = {
- "ParityTypeNone",
- "ParityTypeEven",
- "ParityTypeOdd",
- "ParityTypeMark",
- "ParityTypeSpace",
- "/* UNKNOWN parity keyword */",
- "/* UNKNOWN parity keyword */",
- "/* UNKNOWN parity keyword */"
-};
-
#endif
/*
@@ -305,7 +173,7 @@ const u8 acpi_gbl_resource_aml_sizes[] = {
ACPI_AML_SIZE_SMALL(struct aml_resource_end_dependent),
ACPI_AML_SIZE_SMALL(struct aml_resource_io),
ACPI_AML_SIZE_SMALL(struct aml_resource_fixed_io),
- ACPI_AML_SIZE_SMALL(struct aml_resource_fixed_dma),
+ 0,
0,
0,
0,
@@ -325,17 +193,7 @@ const u8 acpi_gbl_resource_aml_sizes[] = {
ACPI_AML_SIZE_LARGE(struct aml_resource_address16),
ACPI_AML_SIZE_LARGE(struct aml_resource_extended_irq),
ACPI_AML_SIZE_LARGE(struct aml_resource_address64),
- ACPI_AML_SIZE_LARGE(struct aml_resource_extended_address64),
- ACPI_AML_SIZE_LARGE(struct aml_resource_gpio),
- 0,
- ACPI_AML_SIZE_LARGE(struct aml_resource_common_serialbus),
-};
-
-const u8 acpi_gbl_resource_aml_serial_bus_sizes[] = {
- 0,
- ACPI_AML_SIZE_LARGE(struct aml_resource_i2c_serialbus),
- ACPI_AML_SIZE_LARGE(struct aml_resource_spi_serialbus),
- ACPI_AML_SIZE_LARGE(struct aml_resource_uart_serialbus),
+ ACPI_AML_SIZE_LARGE(struct aml_resource_extended_address64)
};
/*
@@ -351,49 +209,35 @@ static const u8 acpi_gbl_resource_types[] = {
0,
0,
0,
- ACPI_SMALL_VARIABLE_LENGTH, /* 04 IRQ */
- ACPI_FIXED_LENGTH, /* 05 DMA */
- ACPI_SMALL_VARIABLE_LENGTH, /* 06 start_dependent_functions */
- ACPI_FIXED_LENGTH, /* 07 end_dependent_functions */
- ACPI_FIXED_LENGTH, /* 08 IO */
- ACPI_FIXED_LENGTH, /* 09 fixed_iO */
- ACPI_FIXED_LENGTH, /* 0_a fixed_dMA */
+ ACPI_SMALL_VARIABLE_LENGTH,
+ ACPI_FIXED_LENGTH,
+ ACPI_SMALL_VARIABLE_LENGTH,
+ ACPI_FIXED_LENGTH,
+ ACPI_FIXED_LENGTH,
+ ACPI_FIXED_LENGTH,
+ 0,
0,
0,
0,
- ACPI_VARIABLE_LENGTH, /* 0_e vendor_short */
- ACPI_FIXED_LENGTH, /* 0_f end_tag */
+ ACPI_VARIABLE_LENGTH,
+ ACPI_FIXED_LENGTH,
/* Large descriptors */
0,
- ACPI_FIXED_LENGTH, /* 01 Memory24 */
- ACPI_FIXED_LENGTH, /* 02 generic_register */
+ ACPI_FIXED_LENGTH,
+ ACPI_FIXED_LENGTH,
0,
- ACPI_VARIABLE_LENGTH, /* 04 vendor_long */
- ACPI_FIXED_LENGTH, /* 05 Memory32 */
- ACPI_FIXED_LENGTH, /* 06 memory32_fixed */
- ACPI_VARIABLE_LENGTH, /* 07 Dword* address */
- ACPI_VARIABLE_LENGTH, /* 08 Word* address */
- ACPI_VARIABLE_LENGTH, /* 09 extended_iRQ */
- ACPI_VARIABLE_LENGTH, /* 0_a Qword* address */
- ACPI_FIXED_LENGTH, /* 0_b Extended* address */
- ACPI_VARIABLE_LENGTH, /* 0_c Gpio* */
- 0,
- ACPI_VARIABLE_LENGTH /* 0_e *serial_bus */
+ ACPI_VARIABLE_LENGTH,
+ ACPI_FIXED_LENGTH,
+ ACPI_FIXED_LENGTH,
+ ACPI_VARIABLE_LENGTH,
+ ACPI_VARIABLE_LENGTH,
+ ACPI_VARIABLE_LENGTH,
+ ACPI_VARIABLE_LENGTH,
+ ACPI_FIXED_LENGTH
};
-/*
- * For the i_aSL compiler/disassembler, we don't want any error messages
- * because the disassembler uses the resource validation code to determine
- * if Buffer objects are actually Resource Templates.
- */
-#ifdef ACPI_ASL_COMPILER
-#define ACPI_RESOURCE_ERROR(plist)
-#else
-#define ACPI_RESOURCE_ERROR(plist) ACPI_ERROR(plist)
-#endif
-
/*******************************************************************************
*
* FUNCTION: acpi_ut_walk_aml_resources
@@ -421,7 +265,6 @@ acpi_ut_walk_aml_resources(u8 * aml,
u8 resource_index;
u32 length;
u32 offset = 0;
- u8 end_tag[2] = { 0x79, 0x00 };
ACPI_FUNCTION_TRACE(ut_walk_aml_resources);
@@ -443,10 +286,6 @@ acpi_ut_walk_aml_resources(u8 * aml,
status = acpi_ut_validate_resource(aml, &resource_index);
if (ACPI_FAILURE(status)) {
- /*
- * Exit on failure. Cannot continue because the descriptor length
- * may be bogus also.
- */
return_ACPI_STATUS(status);
}
@@ -461,7 +300,7 @@ acpi_ut_walk_aml_resources(u8 * aml,
user_function(aml, length, offset, resource_index,
context);
if (ACPI_FAILURE(status)) {
- return_ACPI_STATUS(status);
+ return (status);
}
}
@@ -494,19 +333,7 @@ acpi_ut_walk_aml_resources(u8 * aml,
/* Did not find an end_tag descriptor */
- if (user_function) {
-
- /* Insert an end_tag anyway. acpi_rs_get_list_length always leaves room */
-
- (void)acpi_ut_validate_resource(end_tag, &resource_index);
- status =
- user_function(end_tag, 2, offset, resource_index, context);
- if (ACPI_FAILURE(status)) {
- return_ACPI_STATUS(status);
- }
- }
-
- return_ACPI_STATUS(AE_AML_NO_RESOURCE_END_TAG);
+ return (AE_AML_NO_RESOURCE_END_TAG);
}
/*******************************************************************************
@@ -527,7 +354,6 @@ acpi_ut_walk_aml_resources(u8 * aml,
acpi_status acpi_ut_validate_resource(void *aml, u8 * return_index)
{
- union aml_resource *aml_resource;
u8 resource_type;
u8 resource_index;
acpi_rs_length resource_length;
@@ -549,7 +375,7 @@ acpi_status acpi_ut_validate_resource(void *aml, u8 * return_index)
/* Verify the large resource type (name) against the max */
if (resource_type > ACPI_RESOURCE_NAME_LARGE_MAX) {
- goto invalid_resource;
+ return (AE_AML_INVALID_RESOURCE_TYPE);
}
/*
@@ -566,17 +392,15 @@ acpi_status acpi_ut_validate_resource(void *aml, u8 * return_index)
((resource_type & ACPI_RESOURCE_NAME_SMALL_MASK) >> 3);
}
- /*
- * Check validity of the resource type, via acpi_gbl_resource_types. Zero
- * indicates an invalid resource.
- */
+ /* Check validity of the resource type, zero indicates name is invalid */
+
if (!acpi_gbl_resource_types[resource_index]) {
- goto invalid_resource;
+ return (AE_AML_INVALID_RESOURCE_TYPE);
}
/*
- * Validate the resource_length field. This ensures that the length
- * is at least reasonable, and guarantees that it is non-zero.
+ * 2) Validate the resource_length field. This ensures that the length
+ * is at least reasonable, and guarantees that it is non-zero.
*/
resource_length = acpi_ut_get_resource_length(aml);
minimum_resource_length = acpi_gbl_resource_aml_sizes[resource_index];
@@ -589,7 +413,7 @@ acpi_status acpi_ut_validate_resource(void *aml, u8 * return_index)
/* Fixed length resource, length must match exactly */
if (resource_length != minimum_resource_length) {
- goto bad_resource_length;
+ return (AE_AML_BAD_RESOURCE_LENGTH);
}
break;
@@ -598,7 +422,7 @@ acpi_status acpi_ut_validate_resource(void *aml, u8 * return_index)
/* Variable length resource, length must be at least the minimum */
if (resource_length < minimum_resource_length) {
- goto bad_resource_length;
+ return (AE_AML_BAD_RESOURCE_LENGTH);
}
break;
@@ -608,7 +432,7 @@ acpi_status acpi_ut_validate_resource(void *aml, u8 * return_index)
if ((resource_length > minimum_resource_length) ||
(resource_length < (minimum_resource_length - 1))) {
- goto bad_resource_length;
+ return (AE_AML_BAD_RESOURCE_LENGTH);
}
break;
@@ -616,23 +440,7 @@ acpi_status acpi_ut_validate_resource(void *aml, u8 * return_index)
/* Shouldn't happen (because of validation earlier), but be sure */
- goto invalid_resource;
- }
-
- aml_resource = ACPI_CAST_PTR(union aml_resource, aml);
- if (resource_type == ACPI_RESOURCE_NAME_SERIAL_BUS) {
-
- /* Validate the bus_type field */
-
- if ((aml_resource->common_serial_bus.type == 0) ||
- (aml_resource->common_serial_bus.type >
- AML_RESOURCE_MAX_SERIALBUSTYPE)) {
- ACPI_RESOURCE_ERROR((AE_INFO,
- "Invalid/unsupported SerialBus resource descriptor: BusType 0x%2.2X",
- aml_resource->common_serial_bus.
- type));
- return (AE_AML_INVALID_RESOURCE_TYPE);
- }
+ return (AE_AML_INVALID_RESOURCE_TYPE);
}
/* Optionally return the resource table index */
@@ -642,22 +450,6 @@ acpi_status acpi_ut_validate_resource(void *aml, u8 * return_index)
}
return (AE_OK);
-
- invalid_resource:
-
- ACPI_RESOURCE_ERROR((AE_INFO,
- "Invalid/unsupported resource descriptor: Type 0x%2.2X",
- resource_type));
- return (AE_AML_INVALID_RESOURCE_TYPE);
-
- bad_resource_length:
-
- ACPI_RESOURCE_ERROR((AE_INFO,
- "Invalid resource descriptor length: Type "
- "0x%2.2X, Length 0x%4.4X, MinLength 0x%4.4X",
- resource_type, resource_length,
- minimum_resource_length));
- return (AE_AML_BAD_RESOURCE_LENGTH);
}
/*******************************************************************************
diff --git a/trunk/drivers/acpi/acpica/utstate.c b/trunk/drivers/acpi/acpica/utstate.c
index 4267477c2797..30c21e1a9360 100644
--- a/trunk/drivers/acpi/acpica/utstate.c
+++ b/trunk/drivers/acpi/acpica/utstate.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utxface.c b/trunk/drivers/acpi/acpica/utxface.c
index 644e8c8ebc4b..420ebfe08c72 100644
--- a/trunk/drivers/acpi/acpica/utxface.c
+++ b/trunk/drivers/acpi/acpica/utxface.c
@@ -5,7 +5,7 @@
*****************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -48,7 +48,6 @@
#include "acnamesp.h"
#include "acdebug.h"
#include "actables.h"
-#include "acinterp.h"
#define _COMPONENT ACPI_UTILITIES
ACPI_MODULE_NAME("utxface")
@@ -641,41 +640,4 @@ acpi_status acpi_install_interface_handler(acpi_interface_handler handler)
}
ACPI_EXPORT_SYMBOL(acpi_install_interface_handler)
-
-/*****************************************************************************
- *
- * FUNCTION: acpi_check_address_range
- *
- * PARAMETERS: space_id - Address space ID
- * Address - Start address
- * Length - Length
- * Warn - TRUE if warning on overlap desired
- *
- * RETURN: Count of the number of conflicts detected.
- *
- * DESCRIPTION: Check if the input address range overlaps any of the
- * ASL operation region address ranges.
- *
- ****************************************************************************/
-u32
-acpi_check_address_range(acpi_adr_space_type space_id,
- acpi_physical_address address,
- acpi_size length, u8 warn)
-{
- u32 overlaps;
- acpi_status status;
-
- status = acpi_ut_acquire_mutex(ACPI_MTX_NAMESPACE);
- if (ACPI_FAILURE(status)) {
- return (0);
- }
-
- overlaps = acpi_ut_check_address_range(space_id, address,
- (u32)length, warn);
-
- (void)acpi_ut_release_mutex(ACPI_MTX_NAMESPACE);
- return (overlaps);
-}
-
-ACPI_EXPORT_SYMBOL(acpi_check_address_range)
#endif /* !ACPI_ASL_COMPILER */
diff --git a/trunk/drivers/acpi/acpica/utxferror.c b/trunk/drivers/acpi/acpica/utxferror.c
index 52b568af1819..8d0245ec4315 100644
--- a/trunk/drivers/acpi/acpica/utxferror.c
+++ b/trunk/drivers/acpi/acpica/utxferror.c
@@ -5,7 +5,7 @@
******************************************************************************/
/*
- * Copyright (C) 2000 - 2012, Intel Corp.
+ * Copyright (C) 2000 - 2011, Intel Corp.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
diff --git a/trunk/drivers/acpi/acpica/utxfmutex.c b/trunk/drivers/acpi/acpica/utxfmutex.c
deleted file mode 100644
index 1427d191d15a..000000000000
--- a/trunk/drivers/acpi/acpica/utxfmutex.c
+++ /dev/null
@@ -1,187 +0,0 @@
-/*******************************************************************************
- *
- * Module Name: utxfmutex - external AML mutex access functions
- *
- ******************************************************************************/
-
-/*
- * Copyright (C) 2000 - 2012, Intel Corp.
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions, and the following disclaimer,
- * without modification.
- * 2. Redistributions in binary form must reproduce at minimum a disclaimer
- * substantially similar to the "NO WARRANTY" disclaimer below
- * ("Disclaimer") and any redistribution must be conditioned upon
- * including a substantially similar Disclaimer requirement for further
- * binary redistribution.
- * 3. Neither the names of the above-listed copyright holders nor the names
- * of any contributors may be used to endorse or promote products derived
- * from this software without specific prior written permission.
- *
- * Alternatively, this software may be distributed under the terms of the
- * GNU General Public License ("GPL") version 2 as published by the Free
- * Software Foundation.
- *
- * NO WARRANTY
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
- * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
- * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGES.
- */
-
-#include
-#include "accommon.h"
-#include "acnamesp.h"
-
-#define _COMPONENT ACPI_UTILITIES
-ACPI_MODULE_NAME("utxfmutex")
-
-/* Local prototypes */
-static acpi_status
-acpi_ut_get_mutex_object(acpi_handle handle,
- acpi_string pathname,
- union acpi_operand_object **ret_obj);
-
-/*******************************************************************************
- *
- * FUNCTION: acpi_ut_get_mutex_object
- *
- * PARAMETERS: Handle - Mutex or prefix handle (optional)
- * Pathname - Mutex pathname (optional)
- * ret_obj - Where the mutex object is returned
- *
- * RETURN: Status
- *
- * DESCRIPTION: Get an AML mutex object. The mutex node is pointed to by
- * Handle:Pathname. Either Handle or Pathname can be NULL, but
- * not both.
- *
- ******************************************************************************/
-
-static acpi_status
-acpi_ut_get_mutex_object(acpi_handle handle,
- acpi_string pathname,
- union acpi_operand_object **ret_obj)
-{
- struct acpi_namespace_node *mutex_node;
- union acpi_operand_object *mutex_obj;
- acpi_status status;
-
- /* Parameter validation */
-
- if (!ret_obj || (!handle && !pathname)) {
- return (AE_BAD_PARAMETER);
- }
-
- /* Get a the namespace node for the mutex */
-
- mutex_node = handle;
- if (pathname != NULL) {
- status = acpi_get_handle(handle, pathname,
- ACPI_CAST_PTR(acpi_handle,
- &mutex_node));
- if (ACPI_FAILURE(status)) {
- return (status);
- }
- }
-
- /* Ensure that we actually have a Mutex object */
-
- if (!mutex_node || (mutex_node->type != ACPI_TYPE_MUTEX)) {
- return (AE_TYPE);
- }
-
- /* Get the low-level mutex object */
-
- mutex_obj = acpi_ns_get_attached_object(mutex_node);
- if (!mutex_obj) {
- return (AE_NULL_OBJECT);
- }
-
- *ret_obj = mutex_obj;
- return (AE_OK);
-}
-
-/*******************************************************************************
- *
- * FUNCTION: acpi_acquire_mutex
- *
- * PARAMETERS: Handle - Mutex or prefix handle (optional)
- * Pathname - Mutex pathname (optional)
- * Timeout - Max time to wait for the lock (millisec)
- *
- * RETURN: Status
- *
- * DESCRIPTION: Acquire an AML mutex. This is a device driver interface to
- * AML mutex objects, and allows for transaction locking between
- * drivers and AML code. The mutex node is pointed to by
- * Handle:Pathname. Either Handle or Pathname can be NULL, but
- * not both.
- *
- ******************************************************************************/
-
-acpi_status
-acpi_acquire_mutex(acpi_handle handle, acpi_string pathname, u16 timeout)
-{
- acpi_status status;
- union acpi_operand_object *mutex_obj;
-
- /* Get the low-level mutex associated with Handle:Pathname */
-
- status = acpi_ut_get_mutex_object(handle, pathname, &mutex_obj);
- if (ACPI_FAILURE(status)) {
- return (status);
- }
-
- /* Acquire the OS mutex */
-
- status = acpi_os_acquire_mutex(mutex_obj->mutex.os_mutex, timeout);
- return (status);
-}
-
-/*******************************************************************************
- *
- * FUNCTION: acpi_release_mutex
- *
- * PARAMETERS: Handle - Mutex or prefix handle (optional)
- * Pathname - Mutex pathname (optional)
- *
- * RETURN: Status
- *
- * DESCRIPTION: Release an AML mutex. This is a device driver interface to
- * AML mutex objects, and allows for transaction locking between
- * drivers and AML code. The mutex node is pointed to by
- * Handle:Pathname. Either Handle or Pathname can be NULL, but
- * not both.
- *
- ******************************************************************************/
-
-acpi_status acpi_release_mutex(acpi_handle handle, acpi_string pathname)
-{
- acpi_status status;
- union acpi_operand_object *mutex_obj;
-
- /* Get the low-level mutex associated with Handle:Pathname */
-
- status = acpi_ut_get_mutex_object(handle, pathname, &mutex_obj);
- if (ACPI_FAILURE(status)) {
- return (status);
- }
-
- /* Release the OS mutex */
-
- acpi_os_release_mutex(mutex_obj->mutex.os_mutex);
- return (AE_OK);
-}
diff --git a/trunk/drivers/acpi/apei/apei-base.c b/trunk/drivers/acpi/apei/apei-base.c
index e45350cb6ac8..61540360d5ce 100644
--- a/trunk/drivers/acpi/apei/apei-base.c
+++ b/trunk/drivers/acpi/apei/apei-base.c
@@ -34,13 +34,13 @@
#include
#include
#include
-#include
#include
#include
#include
#include
#include
#include
+#include
#include "apei-internal.h"
@@ -70,7 +70,7 @@ int __apei_exec_read_register(struct acpi_whea_header *entry, u64 *val)
{
int rc;
- rc = apei_read(val, &entry->register_region);
+ rc = acpi_atomic_read(val, &entry->register_region);
if (rc)
return rc;
*val >>= entry->register_region.bit_offset;
@@ -116,13 +116,13 @@ int __apei_exec_write_register(struct acpi_whea_header *entry, u64 val)
val <<= entry->register_region.bit_offset;
if (entry->flags & APEI_EXEC_PRESERVE_REGISTER) {
u64 valr = 0;
- rc = apei_read(&valr, &entry->register_region);
+ rc = acpi_atomic_read(&valr, &entry->register_region);
if (rc)
return rc;
valr &= ~(entry->mask << entry->register_region.bit_offset);
val |= valr;
}
- rc = apei_write(val, &entry->register_region);
+ rc = acpi_atomic_write(val, &entry->register_region);
return rc;
}
@@ -243,7 +243,7 @@ static int pre_map_gar_callback(struct apei_exec_context *ctx,
u8 ins = entry->instruction;
if (ctx->ins_table[ins].flags & APEI_EXEC_INS_ACCESS_REGISTER)
- return acpi_os_map_generic_address(&entry->register_region);
+ return acpi_pre_map_gar(&entry->register_region);
return 0;
}
@@ -276,7 +276,7 @@ static int post_unmap_gar_callback(struct apei_exec_context *ctx,
u8 ins = entry->instruction;
if (ctx->ins_table[ins].flags & APEI_EXEC_INS_ACCESS_REGISTER)
- acpi_os_unmap_generic_address(&entry->register_region);
+ acpi_post_unmap_gar(&entry->register_region);
return 0;
}
@@ -421,17 +421,6 @@ static int apei_resources_merge(struct apei_resources *resources1,
return 0;
}
-int apei_resources_add(struct apei_resources *resources,
- unsigned long start, unsigned long size,
- bool iomem)
-{
- if (iomem)
- return apei_res_add(&resources->iomem, start, size);
- else
- return apei_res_add(&resources->ioport, start, size);
-}
-EXPORT_SYMBOL_GPL(apei_resources_add);
-
/*
* EINJ has two groups of GARs (EINJ table entry and trigger table
* entry), so common resources are subtracted from the trigger table
@@ -449,19 +438,8 @@ int apei_resources_sub(struct apei_resources *resources1,
}
EXPORT_SYMBOL_GPL(apei_resources_sub);
-static int apei_get_nvs_callback(__u64 start, __u64 size, void *data)
-{
- struct apei_resources *resources = data;
- return apei_res_add(&resources->iomem, start, size);
-}
-
-static int apei_get_nvs_resources(struct apei_resources *resources)
-{
- return acpi_nvs_for_each_region(apei_get_nvs_callback, resources);
-}
-
/*
- * IO memory/port resource management mechanism is used to check
+ * IO memory/port rersource management mechanism is used to check
* whether memory/port area used by GARs conflicts with normal memory
* or IO memory/port of devices.
*/
@@ -470,35 +448,21 @@ int apei_resources_request(struct apei_resources *resources,
{
struct apei_res *res, *res_bak = NULL;
struct resource *r;
- struct apei_resources nvs_resources;
int rc;
rc = apei_resources_sub(resources, &apei_resources_all);
if (rc)
return rc;
- /*
- * Some firmware uses ACPI NVS region, that has been marked as
- * busy, so exclude it from APEI resources to avoid false
- * conflict.
- */
- apei_resources_init(&nvs_resources);
- rc = apei_get_nvs_resources(&nvs_resources);
- if (rc)
- goto res_fini;
- rc = apei_resources_sub(resources, &nvs_resources);
- if (rc)
- goto res_fini;
-
rc = -EINVAL;
list_for_each_entry(res, &resources->iomem, list) {
r = request_mem_region(res->start, res->end - res->start,
desc);
if (!r) {
pr_err(APEI_PFX
- "Can not request [mem %#010llx-%#010llx] for %s registers\n",
+ "Can not request iomem region <%016llx-%016llx> for GARs.\n",
(unsigned long long)res->start,
- (unsigned long long)res->end - 1, desc);
+ (unsigned long long)res->end);
res_bak = res;
goto err_unmap_iomem;
}
@@ -508,9 +472,9 @@ int apei_resources_request(struct apei_resources *resources,
r = request_region(res->start, res->end - res->start, desc);
if (!r) {
pr_err(APEI_PFX
- "Can not request [io %#06llx-%#06llx] for %s registers\n",
+ "Can not request ioport region <%016llx-%016llx> for GARs.\n",
(unsigned long long)res->start,
- (unsigned long long)res->end - 1, desc);
+ (unsigned long long)res->end);
res_bak = res;
goto err_unmap_ioport;
}
@@ -536,8 +500,6 @@ int apei_resources_request(struct apei_resources *resources,
break;
release_mem_region(res->start, res->end - res->start);
}
-res_fini:
- apei_resources_fini(&nvs_resources);
return rc;
}
EXPORT_SYMBOL_GPL(apei_resources_request);
@@ -591,96 +553,6 @@ static int apei_check_gar(struct acpi_generic_address *reg, u64 *paddr)
return 0;
}
-/* read GAR in interrupt (including NMI) or process context */
-int apei_read(u64 *val, struct acpi_generic_address *reg)
-{
- int rc;
- u64 address;
- u32 tmp, width = reg->bit_width;
- acpi_status status;
-
- rc = apei_check_gar(reg, &address);
- if (rc)
- return rc;
-
- if (width == 64)
- width = 32; /* Break into two 32-bit transfers */
-
- *val = 0;
- switch(reg->space_id) {
- case ACPI_ADR_SPACE_SYSTEM_MEMORY:
- status = acpi_os_read_memory((acpi_physical_address)
- address, &tmp, width);
- if (ACPI_FAILURE(status))
- return -EIO;
- *val = tmp;
-
- if (reg->bit_width == 64) {
- /* Read the top 32 bits */
- status = acpi_os_read_memory((acpi_physical_address)
- (address + 4), &tmp, 32);
- if (ACPI_FAILURE(status))
- return -EIO;
- *val |= ((u64)tmp << 32);
- }
- break;
- case ACPI_ADR_SPACE_SYSTEM_IO:
- status = acpi_os_read_port(address, (u32 *)val, reg->bit_width);
- if (ACPI_FAILURE(status))
- return -EIO;
- break;
- default:
- return -EINVAL;
- }
-
- return 0;
-}
-EXPORT_SYMBOL_GPL(apei_read);
-
-/* write GAR in interrupt (including NMI) or process context */
-int apei_write(u64 val, struct acpi_generic_address *reg)
-{
- int rc;
- u64 address;
- u32 width = reg->bit_width;
- acpi_status status;
-
- rc = apei_check_gar(reg, &address);
- if (rc)
- return rc;
-
- if (width == 64)
- width = 32; /* Break into two 32-bit transfers */
-
- switch (reg->space_id) {
- case ACPI_ADR_SPACE_SYSTEM_MEMORY:
- status = acpi_os_write_memory((acpi_physical_address)
- address, ACPI_LODWORD(val),
- width);
- if (ACPI_FAILURE(status))
- return -EIO;
-
- if (reg->bit_width == 64) {
- status = acpi_os_write_memory((acpi_physical_address)
- (address + 4),
- ACPI_HIDWORD(val), 32);
- if (ACPI_FAILURE(status))
- return -EIO;
- }
- break;
- case ACPI_ADR_SPACE_SYSTEM_IO:
- status = acpi_os_write_port(address, val, reg->bit_width);
- if (ACPI_FAILURE(status))
- return -EIO;
- break;
- default:
- return -EINVAL;
- }
-
- return 0;
-}
-EXPORT_SYMBOL_GPL(apei_write);
-
static int collect_res_callback(struct apei_exec_context *ctx,
struct acpi_whea_header *entry,
void *data)
diff --git a/trunk/drivers/acpi/apei/apei-internal.h b/trunk/drivers/acpi/apei/apei-internal.h
index cca240a33038..f57050e7a5e7 100644
--- a/trunk/drivers/acpi/apei/apei-internal.h
+++ b/trunk/drivers/acpi/apei/apei-internal.h
@@ -68,9 +68,6 @@ static inline int apei_exec_run_optional(struct apei_exec_context *ctx, u8 actio
/* IP has been set in instruction function */
#define APEI_EXEC_SET_IP 1
-int apei_read(u64 *val, struct acpi_generic_address *reg);
-int apei_write(u64 val, struct acpi_generic_address *reg);
-
int __apei_exec_read_register(struct acpi_whea_header *entry, u64 *val);
int __apei_exec_write_register(struct acpi_whea_header *entry, u64 val);
int apei_exec_read_register(struct apei_exec_context *ctx,
@@ -98,9 +95,6 @@ static inline void apei_resources_init(struct apei_resources *resources)
}
void apei_resources_fini(struct apei_resources *resources);
-int apei_resources_add(struct apei_resources *resources,
- unsigned long start, unsigned long size,
- bool iomem);
int apei_resources_sub(struct apei_resources *resources1,
struct apei_resources *resources2);
int apei_resources_request(struct apei_resources *resources,
diff --git a/trunk/drivers/acpi/apei/einj.c b/trunk/drivers/acpi/apei/einj.c
index 5b898d4dda99..589b96c38704 100644
--- a/trunk/drivers/acpi/apei/einj.c
+++ b/trunk/drivers/acpi/apei/einj.c
@@ -42,42 +42,6 @@
/* Firmware should respond within 1 milliseconds */
#define FIRMWARE_TIMEOUT (1 * NSEC_PER_MSEC)
-/*
- * ACPI version 5 provides a SET_ERROR_TYPE_WITH_ADDRESS action.
- */
-static int acpi5;
-
-struct set_error_type_with_address {
- u32 type;
- u32 vendor_extension;
- u32 flags;
- u32 apicid;
- u64 memory_address;
- u64 memory_address_range;
- u32 pcie_sbdf;
-};
-enum {
- SETWA_FLAGS_APICID = 1,
- SETWA_FLAGS_MEM = 2,
- SETWA_FLAGS_PCIE_SBDF = 4,
-};
-
-/*
- * Vendor extensions for platform specific operations
- */
-struct vendor_error_type_extension {
- u32 length;
- u32 pcie_sbdf;
- u16 vendor_id;
- u16 device_id;
- u8 rev_id;
- u8 reserved[3];
-};
-
-static u32 vendor_flags;
-static struct debugfs_blob_wrapper vendor_blob;
-static char vendor_dev[64];
-
/*
* Some BIOSes allow parameters to the SET_ERROR_TYPE entries in the
* EINJ table through an unpublished extension. Use with caution as
@@ -139,14 +103,7 @@ static struct apei_exec_ins_type einj_ins_type[] = {
*/
static DEFINE_MUTEX(einj_mutex);
-static void *einj_param;
-
-#ifndef readq
-static inline __u64 readq(volatile void __iomem *addr)
-{
- return ((__u64)readl(addr+4) << 32) + readl(addr);
-}
-#endif
+static struct einj_parameter *einj_param;
#ifndef writeq
static inline void writeq(__u64 val, volatile void __iomem *addr)
@@ -201,31 +158,10 @@ static int einj_timedout(u64 *t)
return 0;
}
-static void check_vendor_extension(u64 paddr,
- struct set_error_type_with_address *v5param)
-{
- int offset = readl(&v5param->vendor_extension);
- struct vendor_error_type_extension *v;
- u32 sbdf;
-
- if (!offset)
- return;
- v = ioremap(paddr + offset, sizeof(*v));
- if (!v)
- return;
- sbdf = readl(&v->pcie_sbdf);
- sprintf(vendor_dev, "%x:%x:%x.%x vendor_id=%x device_id=%x rev_id=%x\n",
- sbdf >> 24, (sbdf >> 16) & 0xff,
- (sbdf >> 11) & 0x1f, (sbdf >> 8) & 0x7,
- readw(&v->vendor_id), readw(&v->device_id),
- readb(&v->rev_id));
- iounmap(v);
-}
-
-static void *einj_get_parameter_address(void)
+static u64 einj_get_parameter_address(void)
{
int i;
- u64 paddrv4 = 0, paddrv5 = 0;
+ u64 paddr = 0;
struct acpi_whea_header *entry;
entry = EINJ_TAB_ENTRY(einj_tab);
@@ -234,40 +170,12 @@ static void *einj_get_parameter_address(void)
entry->instruction == ACPI_EINJ_WRITE_REGISTER &&
entry->register_region.space_id ==
ACPI_ADR_SPACE_SYSTEM_MEMORY)
- memcpy(&paddrv4, &entry->register_region.address,
- sizeof(paddrv4));
- if (entry->action == ACPI_EINJ_SET_ERROR_TYPE_WITH_ADDRESS &&
- entry->instruction == ACPI_EINJ_WRITE_REGISTER &&
- entry->register_region.space_id ==
- ACPI_ADR_SPACE_SYSTEM_MEMORY)
- memcpy(&paddrv5, &entry->register_region.address,
- sizeof(paddrv5));
+ memcpy(&paddr, &entry->register_region.address,
+ sizeof(paddr));
entry++;
}
- if (paddrv5) {
- struct set_error_type_with_address *v5param;
-
- v5param = ioremap(paddrv5, sizeof(*v5param));
- if (v5param) {
- acpi5 = 1;
- check_vendor_extension(paddrv5, v5param);
- return v5param;
- }
- }
- if (paddrv4) {
- struct einj_parameter *v4param;
-
- v4param = ioremap(paddrv4, sizeof(*v4param));
- if (!v4param)
- return 0;
- if (readq(&v4param->reserved1) || readq(&v4param->reserved2)) {
- iounmap(v4param);
- return 0;
- }
- return v4param;
- }
- return 0;
+ return paddr;
}
/* do sanity check to trigger table */
@@ -286,29 +194,8 @@ static int einj_check_trigger_header(struct acpi_einj_trigger *trigger_tab)
return 0;
}
-static struct acpi_generic_address *einj_get_trigger_parameter_region(
- struct acpi_einj_trigger *trigger_tab, u64 param1, u64 param2)
-{
- int i;
- struct acpi_whea_header *entry;
-
- entry = (struct acpi_whea_header *)
- ((char *)trigger_tab + sizeof(struct acpi_einj_trigger));
- for (i = 0; i < trigger_tab->entry_count; i++) {
- if (entry->action == ACPI_EINJ_TRIGGER_ERROR &&
- entry->instruction == ACPI_EINJ_WRITE_REGISTER_VALUE &&
- entry->register_region.space_id ==
- ACPI_ADR_SPACE_SYSTEM_MEMORY &&
- (entry->register_region.address & param2) == (param1 & param2))
- return &entry->register_region;
- entry++;
- }
-
- return NULL;
-}
/* Execute instructions in trigger error action table */
-static int __einj_error_trigger(u64 trigger_paddr, u32 type,
- u64 param1, u64 param2)
+static int __einj_error_trigger(u64 trigger_paddr)
{
struct acpi_einj_trigger *trigger_tab = NULL;
struct apei_exec_context trigger_ctx;
@@ -317,16 +204,14 @@ static int __einj_error_trigger(u64 trigger_paddr, u32 type,
struct resource *r;
u32 table_size;
int rc = -EIO;
- struct acpi_generic_address *trigger_param_region = NULL;
r = request_mem_region(trigger_paddr, sizeof(*trigger_tab),
"APEI EINJ Trigger Table");
if (!r) {
pr_err(EINJ_PFX
- "Can not request [mem %#010llx-%#010llx] for Trigger table\n",
+ "Can not request iomem region <%016llx-%016llx> for Trigger table.\n",
(unsigned long long)trigger_paddr,
- (unsigned long long)trigger_paddr +
- sizeof(*trigger_tab) - 1);
+ (unsigned long long)trigger_paddr+sizeof(*trigger_tab));
goto out;
}
trigger_tab = ioremap_cache(trigger_paddr, sizeof(*trigger_tab));
@@ -347,9 +232,9 @@ static int __einj_error_trigger(u64 trigger_paddr, u32 type,
"APEI EINJ Trigger Table");
if (!r) {
pr_err(EINJ_PFX
-"Can not request [mem %#010llx-%#010llx] for Trigger Table Entry\n",
- (unsigned long long)trigger_paddr + sizeof(*trigger_tab),
- (unsigned long long)trigger_paddr + table_size - 1);
+"Can not request iomem region <%016llx-%016llx> for Trigger Table Entry.\n",
+ (unsigned long long)trigger_paddr+sizeof(*trigger_tab),
+ (unsigned long long)trigger_paddr + table_size);
goto out_rel_header;
}
iounmap(trigger_tab);
@@ -370,30 +255,6 @@ static int __einj_error_trigger(u64 trigger_paddr, u32 type,
rc = apei_resources_sub(&trigger_resources, &einj_resources);
if (rc)
goto out_fini;
- /*
- * Some firmware will access target address specified in
- * param1 to trigger the error when injecting memory error.
- * This will cause resource conflict with regular memory. So
- * remove it from trigger table resources.
- */
- if (param_extension && (type & 0x0038) && param2) {
- struct apei_resources addr_resources;
- apei_resources_init(&addr_resources);
- trigger_param_region = einj_get_trigger_parameter_region(
- trigger_tab, param1, param2);
- if (trigger_param_region) {
- rc = apei_resources_add(&addr_resources,
- trigger_param_region->address,
- trigger_param_region->bit_width/8, true);
- if (rc)
- goto out_fini;
- rc = apei_resources_sub(&trigger_resources,
- &addr_resources);
- }
- apei_resources_fini(&addr_resources);
- if (rc)
- goto out_fini;
- }
rc = apei_resources_request(&trigger_resources, "APEI EINJ Trigger");
if (rc)
goto out_fini;
@@ -432,56 +293,12 @@ static int __einj_error_inject(u32 type, u64 param1, u64 param2)
if (rc)
return rc;
apei_exec_ctx_set_input(&ctx, type);
- if (acpi5) {
- struct set_error_type_with_address *v5param = einj_param;
-
- writel(type, &v5param->type);
- if (type & 0x80000000) {
- switch (vendor_flags) {
- case SETWA_FLAGS_APICID:
- writel(param1, &v5param->apicid);
- break;
- case SETWA_FLAGS_MEM:
- writeq(param1, &v5param->memory_address);
- writeq(param2, &v5param->memory_address_range);
- break;
- case SETWA_FLAGS_PCIE_SBDF:
- writel(param1, &v5param->pcie_sbdf);
- break;
- }
- writel(vendor_flags, &v5param->flags);
- } else {
- switch (type) {
- case ACPI_EINJ_PROCESSOR_CORRECTABLE:
- case ACPI_EINJ_PROCESSOR_UNCORRECTABLE:
- case ACPI_EINJ_PROCESSOR_FATAL:
- writel(param1, &v5param->apicid);
- writel(SETWA_FLAGS_APICID, &v5param->flags);
- break;
- case ACPI_EINJ_MEMORY_CORRECTABLE:
- case ACPI_EINJ_MEMORY_UNCORRECTABLE:
- case ACPI_EINJ_MEMORY_FATAL:
- writeq(param1, &v5param->memory_address);
- writeq(param2, &v5param->memory_address_range);
- writel(SETWA_FLAGS_MEM, &v5param->flags);
- break;
- case ACPI_EINJ_PCIX_CORRECTABLE:
- case ACPI_EINJ_PCIX_UNCORRECTABLE:
- case ACPI_EINJ_PCIX_FATAL:
- writel(param1, &v5param->pcie_sbdf);
- writel(SETWA_FLAGS_PCIE_SBDF, &v5param->flags);
- break;
- }
- }
- } else {
- rc = apei_exec_run(&ctx, ACPI_EINJ_SET_ERROR_TYPE);
- if (rc)
- return rc;
- if (einj_param) {
- struct einj_parameter *v4param = einj_param;
- writeq(param1, &v4param->param1);
- writeq(param2, &v4param->param2);
- }
+ rc = apei_exec_run(&ctx, ACPI_EINJ_SET_ERROR_TYPE);
+ if (rc)
+ return rc;
+ if (einj_param) {
+ writeq(param1, &einj_param->param1);
+ writeq(param2, &einj_param->param2);
}
rc = apei_exec_run(&ctx, ACPI_EINJ_EXECUTE_OPERATION);
if (rc)
@@ -507,7 +324,7 @@ static int __einj_error_inject(u32 type, u64 param1, u64 param2)
if (rc)
return rc;
trigger_paddr = apei_exec_ctx_get_output(&ctx);
- rc = __einj_error_trigger(trigger_paddr, type, param1, param2);
+ rc = __einj_error_trigger(trigger_paddr);
if (rc)
return rc;
rc = apei_exec_run_optional(&ctx, ACPI_EINJ_END_OPERATION);
@@ -591,25 +408,15 @@ static int error_type_set(void *data, u64 val)
{
int rc;
u32 available_error_type = 0;
- u32 tval, vendor;
-
- /*
- * Vendor defined types have 0x80000000 bit set, and
- * are not enumerated by ACPI_EINJ_GET_ERROR_TYPE
- */
- vendor = val & 0x80000000;
- tval = val & 0x7fffffff;
/* Only one error type can be specified */
- if (tval & (tval - 1))
+ if (val & (val - 1))
+ return -EINVAL;
+ rc = einj_get_available_error_type(&available_error_type);
+ if (rc)
+ return rc;
+ if (!(val & available_error_type))
return -EINVAL;
- if (!vendor) {
- rc = einj_get_available_error_type(&available_error_type);
- if (rc)
- return rc;
- if (!(val & available_error_type))
- return -EINVAL;
- }
error_type = val;
return 0;
@@ -648,6 +455,7 @@ static int einj_check_table(struct acpi_table_einj *einj_tab)
static int __init einj_init(void)
{
int rc;
+ u64 param_paddr;
acpi_status status;
struct dentry *fentry;
struct apei_exec_context ctx;
@@ -657,9 +465,10 @@ static int __init einj_init(void)
status = acpi_get_table(ACPI_SIG_EINJ, 0,
(struct acpi_table_header **)&einj_tab);
- if (status == AE_NOT_FOUND)
+ if (status == AE_NOT_FOUND) {
+ pr_info(EINJ_PFX "Table is not found!\n");
return -ENODEV;
- else if (ACPI_FAILURE(status)) {
+ } else if (ACPI_FAILURE(status)) {
const char *msg = acpi_format_exception(status);
pr_err(EINJ_PFX "Failed to get table, %s\n", msg);
return -EINVAL;
@@ -700,30 +509,23 @@ static int __init einj_init(void)
rc = apei_exec_pre_map_gars(&ctx);
if (rc)
goto err_release;
-
- einj_param = einj_get_parameter_address();
- if ((param_extension || acpi5) && einj_param) {
- fentry = debugfs_create_x64("param1", S_IRUSR | S_IWUSR,
- einj_debug_dir, &error_param1);
- if (!fentry)
- goto err_unmap;
- fentry = debugfs_create_x64("param2", S_IRUSR | S_IWUSR,
- einj_debug_dir, &error_param2);
- if (!fentry)
- goto err_unmap;
- }
-
- if (vendor_dev[0]) {
- vendor_blob.data = vendor_dev;
- vendor_blob.size = strlen(vendor_dev);
- fentry = debugfs_create_blob("vendor", S_IRUSR,
- einj_debug_dir, &vendor_blob);
- if (!fentry)
- goto err_unmap;
- fentry = debugfs_create_x32("vendor_flags", S_IRUSR | S_IWUSR,
- einj_debug_dir, &vendor_flags);
- if (!fentry)
- goto err_unmap;
+ if (param_extension) {
+ param_paddr = einj_get_parameter_address();
+ if (param_paddr) {
+ einj_param = ioremap(param_paddr, sizeof(*einj_param));
+ rc = -ENOMEM;
+ if (!einj_param)
+ goto err_unmap;
+ fentry = debugfs_create_x64("param1", S_IRUSR | S_IWUSR,
+ einj_debug_dir, &error_param1);
+ if (!fentry)
+ goto err_unmap;
+ fentry = debugfs_create_x64("param2", S_IRUSR | S_IWUSR,
+ einj_debug_dir, &error_param2);
+ if (!fentry)
+ goto err_unmap;
+ } else
+ pr_warn(EINJ_PFX "Parameter extension is not supported.\n");
}
pr_info(EINJ_PFX "Error INJection is initialized.\n");
diff --git a/trunk/drivers/acpi/apei/erst.c b/trunk/drivers/acpi/apei/erst.c
index eb9fab5b96e4..6a9e3bad13f4 100644
--- a/trunk/drivers/acpi/apei/erst.c
+++ b/trunk/drivers/acpi/apei/erst.c
@@ -1127,9 +1127,10 @@ static int __init erst_init(void)
status = acpi_get_table(ACPI_SIG_ERST, 0,
(struct acpi_table_header **)&erst_tab);
- if (status == AE_NOT_FOUND)
+ if (status == AE_NOT_FOUND) {
+ pr_info(ERST_PFX "Table is not found!\n");
goto err;
- else if (ACPI_FAILURE(status)) {
+ } else if (ACPI_FAILURE(status)) {
const char *msg = acpi_format_exception(status);
pr_err(ERST_PFX "Failed to get table, %s\n", msg);
rc = -EINVAL;
diff --git a/trunk/drivers/acpi/apei/ghes.c b/trunk/drivers/acpi/apei/ghes.c
index 9b3cac0abecc..ebaf037a787b 100644
--- a/trunk/drivers/acpi/apei/ghes.c
+++ b/trunk/drivers/acpi/apei/ghes.c
@@ -33,7 +33,6 @@
#include
#include
#include
-#include
#include
#include
#include
@@ -46,9 +45,8 @@
#include
#include
#include
-#include
-#include
#include
+#include
#include
#include
#include
@@ -301,7 +299,7 @@ static struct ghes *ghes_new(struct acpi_hest_generic *generic)
if (!ghes)
return ERR_PTR(-ENOMEM);
ghes->generic = generic;
- rc = acpi_os_map_generic_address(&generic->error_status_address);
+ rc = acpi_pre_map_gar(&generic->error_status_address);
if (rc)
goto err_free;
error_block_length = generic->error_block_length;
@@ -321,7 +319,7 @@ static struct ghes *ghes_new(struct acpi_hest_generic *generic)
return ghes;
err_unmap:
- acpi_os_unmap_generic_address(&generic->error_status_address);
+ acpi_post_unmap_gar(&generic->error_status_address);
err_free:
kfree(ghes);
return ERR_PTR(rc);
@@ -330,7 +328,7 @@ static struct ghes *ghes_new(struct acpi_hest_generic *generic)
static void ghes_fini(struct ghes *ghes)
{
kfree(ghes->estatus);
- acpi_os_unmap_generic_address(&ghes->generic->error_status_address);
+ acpi_post_unmap_gar(&ghes->generic->error_status_address);
}
enum {
@@ -401,7 +399,7 @@ static int ghes_read_estatus(struct ghes *ghes, int silent)
u32 len;
int rc;
- rc = apei_read(&buf_paddr, &g->error_status_address);
+ rc = acpi_atomic_read(&buf_paddr, &g->error_status_address);
if (rc) {
if (!silent && printk_ratelimit())
pr_warning(FW_WARN GHES_PFX
@@ -478,27 +476,6 @@ static void ghes_do_proc(const struct acpi_hest_generic_status *estatus)
}
#endif
}
-#ifdef CONFIG_ACPI_APEI_PCIEAER
- else if (!uuid_le_cmp(*(uuid_le *)gdata->section_type,
- CPER_SEC_PCIE)) {
- struct cper_sec_pcie *pcie_err;
- pcie_err = (struct cper_sec_pcie *)(gdata+1);
- if (sev == GHES_SEV_RECOVERABLE &&
- sec_sev == GHES_SEV_RECOVERABLE &&
- pcie_err->validation_bits & CPER_PCIE_VALID_DEVICE_ID &&
- pcie_err->validation_bits & CPER_PCIE_VALID_AER_INFO) {
- unsigned int devfn;
- int aer_severity;
- devfn = PCI_DEVFN(pcie_err->device_id.device,
- pcie_err->device_id.function);
- aer_severity = cper_severity_to_aer(sev);
- aer_recover_queue(pcie_err->device_id.segment,
- pcie_err->device_id.bus,
- devfn, aer_severity);
- }
-
- }
-#endif
}
}
@@ -506,22 +483,16 @@ static void __ghes_print_estatus(const char *pfx,
const struct acpi_hest_generic *generic,
const struct acpi_hest_generic_status *estatus)
{
- static atomic_t seqno;
- unsigned int curr_seqno;
- char pfx_seq[64];
-
if (pfx == NULL) {
if (ghes_severity(estatus->error_severity) <=
GHES_SEV_CORRECTED)
- pfx = KERN_WARNING;
+ pfx = KERN_WARNING HW_ERR;
else
- pfx = KERN_ERR;
+ pfx = KERN_ERR HW_ERR;
}
- curr_seqno = atomic_inc_return(&seqno);
- snprintf(pfx_seq, sizeof(pfx_seq), "%s{%u}" HW_ERR, pfx, curr_seqno);
printk("%s""Hardware error from APEI Generic Hardware Error Source: %d\n",
- pfx_seq, generic->header.source_id);
- apei_estatus_print(pfx_seq, estatus);
+ pfx, generic->header.source_id);
+ apei_estatus_print(pfx, estatus);
}
static int ghes_print_estatus(const char *pfx,
@@ -740,34 +711,26 @@ static int ghes_notify_sci(struct notifier_block *this,
return ret;
}
-static struct llist_node *llist_nodes_reverse(struct llist_node *llnode)
-{
- struct llist_node *next, *tail = NULL;
-
- while (llnode) {
- next = llnode->next;
- llnode->next = tail;
- tail = llnode;
- llnode = next;
- }
-
- return tail;
-}
-
static void ghes_proc_in_irq(struct irq_work *irq_work)
{
- struct llist_node *llnode, *next;
+ struct llist_node *llnode, *next, *tail = NULL;
struct ghes_estatus_node *estatus_node;
struct acpi_hest_generic *generic;
struct acpi_hest_generic_status *estatus;
u32 len, node_len;
- llnode = llist_del_all(&ghes_estatus_llist);
/*
* Because the time order of estatus in list is reversed,
* revert it back to proper order.
*/
- llnode = llist_nodes_reverse(llnode);
+ llnode = llist_del_all(&ghes_estatus_llist);
+ while (llnode) {
+ next = llnode->next;
+ llnode->next = tail;
+ tail = llnode;
+ llnode = next;
+ }
+ llnode = tail;
while (llnode) {
next = llnode->next;
estatus_node = llist_entry(llnode, struct ghes_estatus_node,
@@ -787,32 +750,6 @@ static void ghes_proc_in_irq(struct irq_work *irq_work)
}
}
-static void ghes_print_queued_estatus(void)
-{
- struct llist_node *llnode;
- struct ghes_estatus_node *estatus_node;
- struct acpi_hest_generic *generic;
- struct acpi_hest_generic_status *estatus;
- u32 len, node_len;
-
- llnode = llist_del_all(&ghes_estatus_llist);
- /*
- * Because the time order of estatus in list is reversed,
- * revert it back to proper order.
- */
- llnode = llist_nodes_reverse(llnode);
- while (llnode) {
- estatus_node = llist_entry(llnode, struct ghes_estatus_node,
- llnode);
- estatus = GHES_ESTATUS_FROM_NODE(estatus_node);
- len = apei_estatus_len(estatus);
- node_len = GHES_ESTATUS_NODE_LEN(len);
- generic = estatus_node->generic;
- ghes_print_estatus(NULL, generic, estatus);
- llnode = llnode->next;
- }
-}
-
static int ghes_notify_nmi(unsigned int cmd, struct pt_regs *regs)
{
struct ghes *ghes, *ghes_global = NULL;
@@ -838,8 +775,7 @@ static int ghes_notify_nmi(unsigned int cmd, struct pt_regs *regs)
if (sev_global >= GHES_SEV_PANIC) {
oops_begin();
- ghes_print_queued_estatus();
- __ghes_print_estatus(KERN_EMERG, ghes_global->generic,
+ __ghes_print_estatus(KERN_EMERG HW_ERR, ghes_global->generic,
ghes_global->estatus);
/* reboot to log the error! */
if (panic_timeout == 0)
diff --git a/trunk/drivers/acpi/apei/hest.c b/trunk/drivers/acpi/apei/hest.c
index 7f00cf38098f..ee7fddc4665c 100644
--- a/trunk/drivers/acpi/apei/hest.c
+++ b/trunk/drivers/acpi/apei/hest.c
@@ -221,9 +221,10 @@ void __init acpi_hest_init(void)
status = acpi_get_table(ACPI_SIG_HEST, 0,
(struct acpi_table_header **)&hest_tab);
- if (status == AE_NOT_FOUND)
+ if (status == AE_NOT_FOUND) {
+ pr_info(HEST_PFX "Table not found.\n");
goto err;
- else if (ACPI_FAILURE(status)) {
+ } else if (ACPI_FAILURE(status)) {
const char *msg = acpi_format_exception(status);
pr_err(HEST_PFX "Failed to get table, %s\n", msg);
rc = -EINVAL;
diff --git a/trunk/drivers/acpi/atomicio.c b/trunk/drivers/acpi/atomicio.c
index d4a5b3d3657b..cfc0cc10af39 100644
--- a/trunk/drivers/acpi/atomicio.c
+++ b/trunk/drivers/acpi/atomicio.c
@@ -32,8 +32,6 @@
#include