mirror of
https://github.com/torvalds/linux.git
synced 2024-12-26 21:02:19 +00:00
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Conflicts: net/bluetooth/l2cap_core.c
This commit is contained in:
commit
6a7ebdf2fd
2
CREDITS
2
CREDITS
@ -518,7 +518,7 @@ N: Zach Brown
|
||||
E: zab@zabbo.net
|
||||
D: maestro pci sound
|
||||
|
||||
M: David Brownell
|
||||
N: David Brownell
|
||||
D: Kernel engineer, mentor, and friend. Maintained USB EHCI and
|
||||
D: gadget layers, SPI subsystem, GPIO subsystem, and more than a few
|
||||
D: device drivers. His encouragement also helped many engineers get
|
||||
|
@ -2,13 +2,7 @@ Intro
|
||||
=====
|
||||
|
||||
This document is designed to provide a list of the minimum levels of
|
||||
software necessary to run the 2.6 kernels, as well as provide brief
|
||||
instructions regarding any other "Gotchas" users may encounter when
|
||||
trying life on the Bleeding Edge. If upgrading from a pre-2.4.x
|
||||
kernel, please consult the Changes file included with 2.4.x kernels for
|
||||
additional information; most of that information will not be repeated
|
||||
here. Basically, this document assumes that your system is already
|
||||
functional and running at least 2.4.x kernels.
|
||||
software necessary to run the 3.0 kernels.
|
||||
|
||||
This document is originally based on my "Changes" file for 2.0.x kernels
|
||||
and therefore owes credit to the same people as that file (Jared Mauch,
|
||||
@ -22,11 +16,10 @@ Upgrade to at *least* these software revisions before thinking you've
|
||||
encountered a bug! If you're unsure what version you're currently
|
||||
running, the suggested command should tell you.
|
||||
|
||||
Again, keep in mind that this list assumes you are already
|
||||
functionally running a Linux 2.4 kernel. Also, not all tools are
|
||||
necessary on all systems; obviously, if you don't have any ISDN
|
||||
hardware, for example, you probably needn't concern yourself with
|
||||
isdn4k-utils.
|
||||
Again, keep in mind that this list assumes you are already functionally
|
||||
running a Linux kernel. Also, not all tools are necessary on all
|
||||
systems; obviously, if you don't have any ISDN hardware, for example,
|
||||
you probably needn't concern yourself with isdn4k-utils.
|
||||
|
||||
o Gnu C 3.2 # gcc --version
|
||||
o Gnu make 3.80 # make --version
|
||||
@ -114,12 +107,12 @@ Ksymoops
|
||||
|
||||
If the unthinkable happens and your kernel oopses, you may need the
|
||||
ksymoops tool to decode it, but in most cases you don't.
|
||||
In the 2.6 kernel it is generally preferred to build the kernel with
|
||||
CONFIG_KALLSYMS so that it produces readable dumps that can be used as-is
|
||||
(this also produces better output than ksymoops).
|
||||
If for some reason your kernel is not build with CONFIG_KALLSYMS and
|
||||
you have no way to rebuild and reproduce the Oops with that option, then
|
||||
you can still decode that Oops with ksymoops.
|
||||
It is generally preferred to build the kernel with CONFIG_KALLSYMS so
|
||||
that it produces readable dumps that can be used as-is (this also
|
||||
produces better output than ksymoops). If for some reason your kernel
|
||||
is not build with CONFIG_KALLSYMS and you have no way to rebuild and
|
||||
reproduce the Oops with that option, then you can still decode that Oops
|
||||
with ksymoops.
|
||||
|
||||
Module-Init-Tools
|
||||
-----------------
|
||||
@ -261,8 +254,8 @@ needs to be recompiled or (preferably) upgraded.
|
||||
NFS-utils
|
||||
---------
|
||||
|
||||
In 2.4 and earlier kernels, the nfs server needed to know about any
|
||||
client that expected to be able to access files via NFS. This
|
||||
In ancient (2.4 and earlier) kernels, the nfs server needed to know
|
||||
about any client that expected to be able to access files via NFS. This
|
||||
information would be given to the kernel by "mountd" when the client
|
||||
mounted the filesystem, or by "exportfs" at system startup. exportfs
|
||||
would take information about active clients from /var/lib/nfs/rmtab.
|
||||
@ -272,11 +265,11 @@ which is not always easy, particularly when trying to implement
|
||||
fail-over. Even when the system is working well, rmtab suffers from
|
||||
getting lots of old entries that never get removed.
|
||||
|
||||
With 2.6 we have the option of having the kernel tell mountd when it
|
||||
gets a request from an unknown host, and mountd can give appropriate
|
||||
export information to the kernel. This removes the dependency on
|
||||
rmtab and means that the kernel only needs to know about currently
|
||||
active clients.
|
||||
With modern kernels we have the option of having the kernel tell mountd
|
||||
when it gets a request from an unknown host, and mountd can give
|
||||
appropriate export information to the kernel. This removes the
|
||||
dependency on rmtab and means that the kernel only needs to know about
|
||||
currently active clients.
|
||||
|
||||
To enable this new functionality, you need to:
|
||||
|
||||
|
@ -680,8 +680,8 @@ ones already enabled by DEBUG.
|
||||
Chapter 14: Allocating memory
|
||||
|
||||
The kernel provides the following general purpose memory allocators:
|
||||
kmalloc(), kzalloc(), kcalloc(), and vmalloc(). Please refer to the API
|
||||
documentation for further information about them.
|
||||
kmalloc(), kzalloc(), kcalloc(), vmalloc(), and vzalloc(). Please refer to
|
||||
the API documentation for further information about them.
|
||||
|
||||
The preferred form for passing a size of a struct is the following:
|
||||
|
||||
|
@ -77,7 +77,7 @@ Throttling/Upper Limit policy
|
||||
- Specify a bandwidth rate on particular device for root group. The format
|
||||
for policy is "<major>:<minor> <byes_per_second>".
|
||||
|
||||
echo "8:16 1048576" > /sys/fs/cgroup/blkio/blkio.read_bps_device
|
||||
echo "8:16 1048576" > /sys/fs/cgroup/blkio/blkio.throttle.read_bps_device
|
||||
|
||||
Above will put a limit of 1MB/second on reads happening for root group
|
||||
on device having major/minor number 8:16.
|
||||
@ -90,7 +90,7 @@ Throttling/Upper Limit policy
|
||||
1024+0 records out
|
||||
4194304 bytes (4.2 MB) copied, 4.0001 s, 1.0 MB/s
|
||||
|
||||
Limits for writes can be put using blkio.write_bps_device file.
|
||||
Limits for writes can be put using blkio.throttle.write_bps_device file.
|
||||
|
||||
Hierarchical Cgroups
|
||||
====================
|
||||
@ -286,28 +286,28 @@ Throttling/Upper limit policy files
|
||||
specified in bytes per second. Rules are per deivce. Following is
|
||||
the format.
|
||||
|
||||
echo "<major>:<minor> <rate_bytes_per_second>" > /cgrp/blkio.read_bps_device
|
||||
echo "<major>:<minor> <rate_bytes_per_second>" > /cgrp/blkio.throttle.read_bps_device
|
||||
|
||||
- blkio.throttle.write_bps_device
|
||||
- Specifies upper limit on WRITE rate to the device. IO rate is
|
||||
specified in bytes per second. Rules are per deivce. Following is
|
||||
the format.
|
||||
|
||||
echo "<major>:<minor> <rate_bytes_per_second>" > /cgrp/blkio.write_bps_device
|
||||
echo "<major>:<minor> <rate_bytes_per_second>" > /cgrp/blkio.throttle.write_bps_device
|
||||
|
||||
- blkio.throttle.read_iops_device
|
||||
- Specifies upper limit on READ rate from the device. IO rate is
|
||||
specified in IO per second. Rules are per deivce. Following is
|
||||
the format.
|
||||
|
||||
echo "<major>:<minor> <rate_io_per_second>" > /cgrp/blkio.read_iops_device
|
||||
echo "<major>:<minor> <rate_io_per_second>" > /cgrp/blkio.throttle.read_iops_device
|
||||
|
||||
- blkio.throttle.write_iops_device
|
||||
- Specifies upper limit on WRITE rate to the device. IO rate is
|
||||
specified in io per second. Rules are per deivce. Following is
|
||||
the format.
|
||||
|
||||
echo "<major>:<minor> <rate_io_per_second>" > /cgrp/blkio.write_iops_device
|
||||
echo "<major>:<minor> <rate_io_per_second>" > /cgrp/blkio.throttle.write_iops_device
|
||||
|
||||
Note: If both BW and IOPS rules are specified for a device, then IO is
|
||||
subjectd to both the constraints.
|
||||
|
@ -583,3 +583,25 @@ Why: Superseded by the UVCIOC_CTRL_QUERY ioctl.
|
||||
Who: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
|
||||
|
||||
----------------------------
|
||||
|
||||
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 <hans.verkuil@cisco.com>
|
||||
|
||||
----------------------------
|
||||
|
||||
What: Opening a radio device node will no longer automatically switch the
|
||||
tuner mode from tv to radio.
|
||||
When: 3.3
|
||||
Why: Just opening a V4L device should not change the state of the hardware
|
||||
like that. It's very unexpected and against the V4L spec. Instead, you
|
||||
switch to radio mode by calling VIDIOC_S_FREQUENCY. This is the second
|
||||
and last step of the move to consistent handling of tv and radio tuners.
|
||||
Who: Hans Verkuil <hans.verkuil@cisco.com>
|
||||
|
||||
----------------------------
|
||||
|
@ -673,6 +673,22 @@ storage request to complete, or it may attempt to cancel the storage request -
|
||||
in which case the page will not be stored in the cache this time.
|
||||
|
||||
|
||||
BULK INODE PAGE UNCACHE
|
||||
-----------------------
|
||||
|
||||
A convenience routine is provided to perform an uncache on all the pages
|
||||
attached to an inode. This assumes that the pages on the inode correspond on a
|
||||
1:1 basis with the pages in the cache.
|
||||
|
||||
void fscache_uncache_all_inode_pages(struct fscache_cookie *cookie,
|
||||
struct inode *inode);
|
||||
|
||||
This takes the netfs cookie that the pages were cached with and the inode that
|
||||
the pages are attached to. This function will wait for pages to finish being
|
||||
written to the cache and for the cache to finish with the page generally. No
|
||||
error is returned.
|
||||
|
||||
|
||||
==========================
|
||||
INDEX AND DATA FILE UPDATE
|
||||
==========================
|
||||
|
@ -22,6 +22,10 @@ Supported chips:
|
||||
Prefix: 'f71869'
|
||||
Addresses scanned: none, address read from Super I/O config space
|
||||
Datasheet: Available from the Fintek website
|
||||
* Fintek F71869A
|
||||
Prefix: 'f71869a'
|
||||
Addresses scanned: none, address read from Super I/O config space
|
||||
Datasheet: Not public
|
||||
* Fintek F71882FG and F71883FG
|
||||
Prefix: 'f71882fg'
|
||||
Addresses scanned: none, address read from Super I/O config space
|
||||
|
@ -9,8 +9,8 @@ Supported chips:
|
||||
Socket S1G3: Athlon II, Sempron, Turion II
|
||||
* AMD Family 11h processors:
|
||||
Socket S1G2: Athlon (X2), Sempron (X2), Turion X2 (Ultra)
|
||||
* AMD Family 12h processors: "Llano"
|
||||
* AMD Family 14h processors: "Brazos" (C/E/G-Series)
|
||||
* AMD Family 12h processors: "Llano" (E2/A4/A6/A8-Series)
|
||||
* AMD Family 14h processors: "Brazos" (C/E/G/Z-Series)
|
||||
* AMD Family 15h processors: "Bulldozer"
|
||||
|
||||
Prefix: 'k10temp'
|
||||
@ -20,12 +20,16 @@ Supported chips:
|
||||
http://support.amd.com/us/Processor_TechDocs/31116.pdf
|
||||
BIOS and Kernel Developer's Guide (BKDG) for AMD Family 11h Processors:
|
||||
http://support.amd.com/us/Processor_TechDocs/41256.pdf
|
||||
BIOS and Kernel Developer's Guide (BKDG) for AMD Family 12h Processors:
|
||||
http://support.amd.com/us/Processor_TechDocs/41131.pdf
|
||||
BIOS and Kernel Developer's Guide (BKDG) for AMD Family 14h Models 00h-0Fh Processors:
|
||||
http://support.amd.com/us/Processor_TechDocs/43170.pdf
|
||||
Revision Guide for AMD Family 10h Processors:
|
||||
http://support.amd.com/us/Processor_TechDocs/41322.pdf
|
||||
Revision Guide for AMD Family 11h Processors:
|
||||
http://support.amd.com/us/Processor_TechDocs/41788.pdf
|
||||
Revision Guide for AMD Family 12h Processors:
|
||||
http://support.amd.com/us/Processor_TechDocs/44739.pdf
|
||||
Revision Guide for AMD Family 14h Models 00h-0Fh Processors:
|
||||
http://support.amd.com/us/Processor_TechDocs/47534.pdf
|
||||
AMD Family 11h Processor Power and Thermal Data Sheet for Notebooks:
|
||||
|
@ -2015,6 +2015,8 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
|
||||
the default.
|
||||
off: Turn ECRC off
|
||||
on: Turn ECRC on.
|
||||
realloc reallocate PCI resources if allocations done by BIOS
|
||||
are erroneous.
|
||||
|
||||
pcie_aspm= [PCIE] Forcibly enable or disable PCIe Active State Power
|
||||
Management.
|
||||
|
@ -534,6 +534,8 @@ Events that are never propagated by the driver:
|
||||
0x2404 System is waking up from hibernation to undock
|
||||
0x2405 System is waking up from hibernation to eject bay
|
||||
0x5010 Brightness level changed/control event
|
||||
0x6000 KEYBOARD: Numlock key pressed
|
||||
0x6005 KEYBOARD: Fn key pressed (TO BE VERIFIED)
|
||||
|
||||
Events that are propagated by the driver to userspace:
|
||||
|
||||
@ -545,6 +547,8 @@ Events that are propagated by the driver to userspace:
|
||||
0x3006 Bay hotplug request (hint to power up SATA link when
|
||||
the optical drive tray is ejected)
|
||||
0x4003 Undocked (see 0x2x04), can sleep again
|
||||
0x4010 Docked into hotplug port replicator (non-ACPI dock)
|
||||
0x4011 Undocked from hotplug port replicator (non-ACPI dock)
|
||||
0x500B Tablet pen inserted into its storage bay
|
||||
0x500C Tablet pen removed from its storage bay
|
||||
0x6011 ALARM: battery is too hot
|
||||
@ -552,6 +556,7 @@ Events that are propagated by the driver to userspace:
|
||||
0x6021 ALARM: a sensor is too hot
|
||||
0x6022 ALARM: a sensor is extremely hot
|
||||
0x6030 System thermal table changed
|
||||
0x6040 Nvidia Optimus/AC adapter related (TO BE VERIFIED)
|
||||
|
||||
Battery nearly empty alarms are a last resort attempt to get the
|
||||
operating system to hibernate or shutdown cleanly (0x2313), or shutdown
|
||||
|
@ -336,7 +336,7 @@ tcp_orphan_retries - INTEGER
|
||||
when RTO retransmissions remain unacknowledged.
|
||||
See tcp_retries2 for more details.
|
||||
|
||||
The default value is 7.
|
||||
The default value is 8.
|
||||
If your machine is a loaded WEB server,
|
||||
you should think about lowering this value, such sockets
|
||||
may consume significant resources. Cf. tcp_max_orphans.
|
||||
|
@ -501,13 +501,29 @@ helper functions described in Section 4. In that case, pm_runtime_resume()
|
||||
should be used. Of course, for this purpose the device's run-time PM has to be
|
||||
enabled earlier by calling pm_runtime_enable().
|
||||
|
||||
If the device bus type's or driver's ->probe() or ->remove() callback runs
|
||||
If the device bus type's or driver's ->probe() callback runs
|
||||
pm_runtime_suspend() or pm_runtime_idle() or their asynchronous counterparts,
|
||||
they will fail returning -EAGAIN, because the device's usage counter is
|
||||
incremented by the core before executing ->probe() and ->remove(). Still, it
|
||||
may be desirable to suspend the device as soon as ->probe() or ->remove() has
|
||||
finished, so the PM core uses pm_runtime_idle_sync() to invoke the
|
||||
subsystem-level idle callback for the device at that time.
|
||||
incremented by the driver core before executing ->probe(). Still, it may be
|
||||
desirable to suspend the device as soon as ->probe() has finished, so the driver
|
||||
core uses pm_runtime_put_sync() to invoke the subsystem-level idle callback for
|
||||
the device at that time.
|
||||
|
||||
Moreover, the driver core prevents runtime PM callbacks from racing with the bus
|
||||
notifier callback in __device_release_driver(), which is necessary, because the
|
||||
notifier is used by some subsystems to carry out operations affecting the
|
||||
runtime PM functionality. It does so by calling pm_runtime_get_sync() before
|
||||
driver_sysfs_remove() and the BUS_NOTIFY_UNBIND_DRIVER notifications. This
|
||||
resumes the device if it's in the suspended state and prevents it from
|
||||
being suspended again while those routines are being executed.
|
||||
|
||||
To allow bus types and drivers to put devices into the suspended state by
|
||||
calling pm_runtime_suspend() from their ->remove() routines, the driver core
|
||||
executes pm_runtime_put_sync() after running the BUS_NOTIFY_UNBIND_DRIVER
|
||||
notifications in __device_release_driver(). This requires bus types and
|
||||
drivers to make their ->remove() callbacks avoid races with runtime PM directly,
|
||||
but also it allows of more flexibility in the handling of devices during the
|
||||
removal of their drivers.
|
||||
|
||||
The user space can effectively disallow the driver of the device to power manage
|
||||
it at run time by changing the value of its /sys/devices/.../power/control
|
||||
|
@ -13,18 +13,8 @@ static DEFINE_SPINLOCK(xxx_lock);
|
||||
The above is always safe. It will disable interrupts _locally_, but the
|
||||
spinlock itself will guarantee the global lock, so it will guarantee that
|
||||
there is only one thread-of-control within the region(s) protected by that
|
||||
lock. This works well even under UP. The above sequence under UP
|
||||
essentially is just the same as doing
|
||||
|
||||
unsigned long flags;
|
||||
|
||||
save_flags(flags); cli();
|
||||
... critical section ...
|
||||
restore_flags(flags);
|
||||
|
||||
so the code does _not_ need to worry about UP vs SMP issues: the spinlocks
|
||||
work correctly under both (and spinlocks are actually more efficient on
|
||||
architectures that allow doing the "save_flags + cli" in one operation).
|
||||
lock. This works well even under UP also, so the code does _not_ need to
|
||||
worry about UP vs SMP issues: the spinlocks work correctly under both.
|
||||
|
||||
NOTE! Implications of spin_locks for memory are further described in:
|
||||
|
||||
@ -36,27 +26,7 @@ The above is usually pretty simple (you usually need and want only one
|
||||
spinlock for most things - using more than one spinlock can make things a
|
||||
lot more complex and even slower and is usually worth it only for
|
||||
sequences that you _know_ need to be split up: avoid it at all cost if you
|
||||
aren't sure). HOWEVER, it _does_ mean that if you have some code that does
|
||||
|
||||
cli();
|
||||
.. critical section ..
|
||||
sti();
|
||||
|
||||
and another sequence that does
|
||||
|
||||
spin_lock_irqsave(flags);
|
||||
.. critical section ..
|
||||
spin_unlock_irqrestore(flags);
|
||||
|
||||
then they are NOT mutually exclusive, and the critical regions can happen
|
||||
at the same time on two different CPU's. That's fine per se, but the
|
||||
critical regions had better be critical for different things (ie they
|
||||
can't stomp on each other).
|
||||
|
||||
The above is a problem mainly if you end up mixing code - for example the
|
||||
routines in ll_rw_block() tend to use cli/sti to protect the atomicity of
|
||||
their actions, and if a driver uses spinlocks instead then you should
|
||||
think about issues like the above.
|
||||
aren't sure).
|
||||
|
||||
This is really the only really hard part about spinlocks: once you start
|
||||
using spinlocks they tend to expand to areas you might not have noticed
|
||||
@ -120,11 +90,10 @@ Lesson 3: spinlocks revisited.
|
||||
|
||||
The single spin-lock primitives above are by no means the only ones. They
|
||||
are the most safe ones, and the ones that work under all circumstances,
|
||||
but partly _because_ they are safe they are also fairly slow. They are
|
||||
much faster than a generic global cli/sti pair, but slower than they'd
|
||||
need to be, because they do have to disable interrupts (which is just a
|
||||
single instruction on a x86, but it's an expensive one - and on other
|
||||
architectures it can be worse).
|
||||
but partly _because_ they are safe they are also fairly slow. They are slower
|
||||
than they'd need to be, because they do have to disable interrupts
|
||||
(which is just a single instruction on a x86, but it's an expensive one -
|
||||
and on other architectures it can be worse).
|
||||
|
||||
If you have a case where you have to protect a data structure across
|
||||
several CPU's and you want to use spinlocks you can potentially use
|
||||
|
15
MAINTAINERS
15
MAINTAINERS
@ -594,6 +594,16 @@ S: Maintained
|
||||
F: arch/arm/lib/floppydma.S
|
||||
F: arch/arm/include/asm/floppy.h
|
||||
|
||||
ARM PMU PROFILING AND DEBUGGING
|
||||
M: Will Deacon <will.deacon@arm.com>
|
||||
S: Maintained
|
||||
F: arch/arm/kernel/perf_event*
|
||||
F: arch/arm/oprofile/common.c
|
||||
F: arch/arm/kernel/pmu.c
|
||||
F: arch/arm/include/asm/pmu.h
|
||||
F: arch/arm/kernel/hw_breakpoint.c
|
||||
F: arch/arm/include/asm/hw_breakpoint.h
|
||||
|
||||
ARM PORT
|
||||
M: Russell King <linux@arm.linux.org.uk>
|
||||
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||
@ -2197,7 +2207,7 @@ F: drivers/acpi/dock.c
|
||||
DOCUMENTATION
|
||||
M: Randy Dunlap <rdunlap@xenotime.net>
|
||||
L: linux-doc@vger.kernel.org
|
||||
T: quilt oss.oracle.com/~rdunlap/kernel-doc-patches/current/
|
||||
T: quilt http://userweb.kernel.org/~rdunlap/kernel-doc-patches/current/
|
||||
S: Maintained
|
||||
F: Documentation/
|
||||
|
||||
@ -4982,7 +4992,7 @@ F: drivers/power/power_supply*
|
||||
|
||||
PNP SUPPORT
|
||||
M: Adam Belay <abelay@mit.edu>
|
||||
M: Bjorn Helgaas <bjorn.helgaas@hp.com>
|
||||
M: Bjorn Helgaas <bhelgaas@google.com>
|
||||
S: Maintained
|
||||
F: drivers/pnp/
|
||||
|
||||
@ -6733,6 +6743,7 @@ F: fs/fat/
|
||||
VIDEOBUF2 FRAMEWORK
|
||||
M: Pawel Osciak <pawel@osciak.com>
|
||||
M: Marek Szyprowski <m.szyprowski@samsung.com>
|
||||
M: Kyungmin Park <kyungmin.park@samsung.com>
|
||||
L: linux-media@vger.kernel.org
|
||||
S: Maintained
|
||||
F: drivers/media/video/videobuf2-*
|
||||
|
2
Makefile
2
Makefile
@ -1,7 +1,7 @@
|
||||
VERSION = 3
|
||||
PATCHLEVEL = 0
|
||||
SUBLEVEL = 0
|
||||
EXTRAVERSION = -rc5
|
||||
EXTRAVERSION = -rc7
|
||||
NAME = Sneaky Weasel
|
||||
|
||||
# *DOCUMENTATION*
|
||||
|
42
README
42
README
@ -1,6 +1,6 @@
|
||||
Linux kernel release 2.6.xx <http://kernel.org/>
|
||||
Linux kernel release 3.x <http://kernel.org/>
|
||||
|
||||
These are the release notes for Linux version 2.6. Read them carefully,
|
||||
These are the release notes for Linux version 3. Read them carefully,
|
||||
as they tell you what this is all about, explain how to install the
|
||||
kernel, and what to do if something goes wrong.
|
||||
|
||||
@ -62,10 +62,10 @@ INSTALLING the kernel source:
|
||||
directory where you have permissions (eg. your home directory) and
|
||||
unpack it:
|
||||
|
||||
gzip -cd linux-2.6.XX.tar.gz | tar xvf -
|
||||
gzip -cd linux-3.X.tar.gz | tar xvf -
|
||||
|
||||
or
|
||||
bzip2 -dc linux-2.6.XX.tar.bz2 | tar xvf -
|
||||
bzip2 -dc linux-3.X.tar.bz2 | tar xvf -
|
||||
|
||||
|
||||
Replace "XX" with the version number of the latest kernel.
|
||||
@ -75,15 +75,15 @@ INSTALLING the kernel source:
|
||||
files. They should match the library, and not get messed up by
|
||||
whatever the kernel-du-jour happens to be.
|
||||
|
||||
- You can also upgrade between 2.6.xx releases by patching. Patches are
|
||||
- You can also upgrade between 3.x releases by patching. Patches are
|
||||
distributed in the traditional gzip and the newer bzip2 format. To
|
||||
install by patching, get all the newer patch files, enter the
|
||||
top level directory of the kernel source (linux-2.6.xx) and execute:
|
||||
top level directory of the kernel source (linux-3.x) and execute:
|
||||
|
||||
gzip -cd ../patch-2.6.xx.gz | patch -p1
|
||||
gzip -cd ../patch-3.x.gz | patch -p1
|
||||
|
||||
or
|
||||
bzip2 -dc ../patch-2.6.xx.bz2 | patch -p1
|
||||
bzip2 -dc ../patch-3.x.bz2 | patch -p1
|
||||
|
||||
(repeat xx for all versions bigger than the version of your current
|
||||
source tree, _in_order_) and you should be ok. You may want to remove
|
||||
@ -91,9 +91,9 @@ INSTALLING the kernel source:
|
||||
failed patches (xxx# or xxx.rej). If there are, either you or me has
|
||||
made a mistake.
|
||||
|
||||
Unlike patches for the 2.6.x kernels, patches for the 2.6.x.y kernels
|
||||
Unlike patches for the 3.x kernels, patches for the 3.x.y kernels
|
||||
(also known as the -stable kernels) are not incremental but instead apply
|
||||
directly to the base 2.6.x kernel. Please read
|
||||
directly to the base 3.x kernel. Please read
|
||||
Documentation/applying-patches.txt for more information.
|
||||
|
||||
Alternatively, the script patch-kernel can be used to automate this
|
||||
@ -107,14 +107,14 @@ INSTALLING the kernel source:
|
||||
an alternative directory can be specified as the second argument.
|
||||
|
||||
- If you are upgrading between releases using the stable series patches
|
||||
(for example, patch-2.6.xx.y), note that these "dot-releases" are
|
||||
not incremental and must be applied to the 2.6.xx base tree. For
|
||||
example, if your base kernel is 2.6.12 and you want to apply the
|
||||
2.6.12.3 patch, you do not and indeed must not first apply the
|
||||
2.6.12.1 and 2.6.12.2 patches. Similarly, if you are running kernel
|
||||
version 2.6.12.2 and want to jump to 2.6.12.3, you must first
|
||||
reverse the 2.6.12.2 patch (that is, patch -R) _before_ applying
|
||||
the 2.6.12.3 patch.
|
||||
(for example, patch-3.x.y), note that these "dot-releases" are
|
||||
not incremental and must be applied to the 3.x base tree. For
|
||||
example, if your base kernel is 3.0 and you want to apply the
|
||||
3.0.3 patch, you do not and indeed must not first apply the
|
||||
3.0.1 and 3.0.2 patches. Similarly, if you are running kernel
|
||||
version 3.0.2 and want to jump to 3.0.3, you must first
|
||||
reverse the 3.0.2 patch (that is, patch -R) _before_ applying
|
||||
the 3.0.3 patch.
|
||||
You can read more on this in Documentation/applying-patches.txt
|
||||
|
||||
- Make sure you have no stale .o files and dependencies lying around:
|
||||
@ -126,7 +126,7 @@ INSTALLING the kernel source:
|
||||
|
||||
SOFTWARE REQUIREMENTS
|
||||
|
||||
Compiling and running the 2.6.xx kernels requires up-to-date
|
||||
Compiling and running the 3.x kernels requires up-to-date
|
||||
versions of various software packages. Consult
|
||||
Documentation/Changes for the minimum version numbers required
|
||||
and how to get updates for these packages. Beware that using
|
||||
@ -142,11 +142,11 @@ BUILD directory for the kernel:
|
||||
Using the option "make O=output/dir" allow you to specify an alternate
|
||||
place for the output files (including .config).
|
||||
Example:
|
||||
kernel source code: /usr/src/linux-2.6.N
|
||||
kernel source code: /usr/src/linux-3.N
|
||||
build directory: /home/name/build/kernel
|
||||
|
||||
To configure and build the kernel use:
|
||||
cd /usr/src/linux-2.6.N
|
||||
cd /usr/src/linux-3.N
|
||||
make O=/home/name/build/kernel menuconfig
|
||||
make O=/home/name/build/kernel
|
||||
sudo make O=/home/name/build/kernel modules_install install
|
||||
|
@ -255,7 +255,7 @@ static inline dma_addr_t map_single(struct device *dev, void *ptr, size_t size,
|
||||
if (buf == 0) {
|
||||
dev_err(dev, "%s: unable to map unsafe buffer %p!\n",
|
||||
__func__, ptr);
|
||||
return 0;
|
||||
return ~0;
|
||||
}
|
||||
|
||||
dev_dbg(dev,
|
||||
|
@ -583,7 +583,7 @@ static int armpmu_event_init(struct perf_event *event)
|
||||
static void armpmu_enable(struct pmu *pmu)
|
||||
{
|
||||
/* Enable all of the perf events on hardware. */
|
||||
int idx;
|
||||
int idx, enabled = 0;
|
||||
struct cpu_hw_events *cpuc = &__get_cpu_var(cpu_hw_events);
|
||||
|
||||
if (!armpmu)
|
||||
@ -596,9 +596,11 @@ static void armpmu_enable(struct pmu *pmu)
|
||||
continue;
|
||||
|
||||
armpmu->enable(&event->hw, idx);
|
||||
enabled = 1;
|
||||
}
|
||||
|
||||
armpmu->start();
|
||||
if (enabled)
|
||||
armpmu->start();
|
||||
}
|
||||
|
||||
static void armpmu_disable(struct pmu *pmu)
|
||||
|
@ -73,6 +73,7 @@ __setup("fpe=", fpe_setup);
|
||||
#endif
|
||||
|
||||
extern void paging_init(struct machine_desc *desc);
|
||||
extern void sanity_check_meminfo(void);
|
||||
extern void reboot_setup(char *str);
|
||||
|
||||
unsigned int processor_id;
|
||||
@ -900,6 +901,7 @@ void __init setup_arch(char **cmdline_p)
|
||||
|
||||
parse_early_param();
|
||||
|
||||
sanity_check_meminfo();
|
||||
arm_memblock_init(&meminfo, mdesc);
|
||||
|
||||
paging_init(mdesc);
|
||||
|
@ -115,7 +115,7 @@ static void __cpuinit twd_calibrate_rate(void)
|
||||
twd_timer_rate = (0xFFFFFFFFU - count) * (HZ / 5);
|
||||
|
||||
printk("%lu.%02luMHz.\n", twd_timer_rate / 1000000,
|
||||
(twd_timer_rate / 1000000) % 100);
|
||||
(twd_timer_rate / 10000) % 100);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -223,15 +223,15 @@ static struct clk *periph_clocks[] __initdata = {
|
||||
};
|
||||
|
||||
static struct clk_lookup periph_clocks_lookups[] = {
|
||||
CLKDEV_CON_DEV_ID("hclk", "atmel_usba_udc.0", &utmi_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "atmel_usba_udc.0", &udphs_clk),
|
||||
CLKDEV_CON_DEV_ID("hclk", "atmel_usba_udc", &utmi_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "atmel_usba_udc", &udphs_clk),
|
||||
CLKDEV_CON_DEV_ID("mci_clk", "at91_mci.0", &mmc0_clk),
|
||||
CLKDEV_CON_DEV_ID("mci_clk", "at91_mci.1", &mmc1_clk),
|
||||
CLKDEV_CON_DEV_ID("spi_clk", "atmel_spi.0", &spi0_clk),
|
||||
CLKDEV_CON_DEV_ID("spi_clk", "atmel_spi.1", &spi1_clk),
|
||||
CLKDEV_CON_DEV_ID("t0_clk", "atmel_tcb.0", &tcb_clk),
|
||||
CLKDEV_CON_DEV_ID("ssc", "ssc.0", &ssc0_clk),
|
||||
CLKDEV_CON_DEV_ID("ssc", "ssc.1", &ssc1_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "ssc.0", &ssc0_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "ssc.1", &ssc1_clk),
|
||||
};
|
||||
|
||||
static struct clk_lookup usart_clocks_lookups[] = {
|
||||
|
@ -1220,7 +1220,7 @@ void __init at91_set_serial_console(unsigned portnr)
|
||||
{
|
||||
if (portnr < ATMEL_MAX_UART) {
|
||||
atmel_default_console_device = at91_uarts[portnr];
|
||||
at91cap9_set_console_clock(portnr);
|
||||
at91cap9_set_console_clock(at91_uarts[portnr]->id);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -199,9 +199,9 @@ static struct clk_lookup periph_clocks_lookups[] = {
|
||||
CLKDEV_CON_DEV_ID("t0_clk", "atmel_tcb.1", &tc3_clk),
|
||||
CLKDEV_CON_DEV_ID("t1_clk", "atmel_tcb.1", &tc4_clk),
|
||||
CLKDEV_CON_DEV_ID("t2_clk", "atmel_tcb.1", &tc5_clk),
|
||||
CLKDEV_CON_DEV_ID("ssc", "ssc.0", &ssc0_clk),
|
||||
CLKDEV_CON_DEV_ID("ssc", "ssc.1", &ssc1_clk),
|
||||
CLKDEV_CON_DEV_ID("ssc", "ssc.2", &ssc2_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "ssc.0", &ssc0_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "ssc.1", &ssc1_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "ssc.2", &ssc2_clk),
|
||||
};
|
||||
|
||||
static struct clk_lookup usart_clocks_lookups[] = {
|
||||
|
@ -1135,7 +1135,7 @@ void __init at91_set_serial_console(unsigned portnr)
|
||||
{
|
||||
if (portnr < ATMEL_MAX_UART) {
|
||||
atmel_default_console_device = at91_uarts[portnr];
|
||||
at91rm9200_set_console_clock(portnr);
|
||||
at91rm9200_set_console_clock(at91_uarts[portnr]->id);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1173,7 +1173,7 @@ void __init at91_set_serial_console(unsigned portnr)
|
||||
{
|
||||
if (portnr < ATMEL_MAX_UART) {
|
||||
atmel_default_console_device = at91_uarts[portnr];
|
||||
at91sam9260_set_console_clock(portnr);
|
||||
at91sam9260_set_console_clock(at91_uarts[portnr]->id);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1013,7 +1013,7 @@ void __init at91_set_serial_console(unsigned portnr)
|
||||
{
|
||||
if (portnr < ATMEL_MAX_UART) {
|
||||
atmel_default_console_device = at91_uarts[portnr];
|
||||
at91sam9261_set_console_clock(portnr);
|
||||
at91sam9261_set_console_clock(at91_uarts[portnr]->id);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1395,7 +1395,7 @@ void __init at91_set_serial_console(unsigned portnr)
|
||||
{
|
||||
if (portnr < ATMEL_MAX_UART) {
|
||||
atmel_default_console_device = at91_uarts[portnr];
|
||||
at91sam9263_set_console_clock(portnr);
|
||||
at91sam9263_set_console_clock(at91_uarts[portnr]->id);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -217,11 +217,11 @@ static struct clk *periph_clocks[] __initdata = {
|
||||
static struct clk_lookup periph_clocks_lookups[] = {
|
||||
/* One additional fake clock for ohci */
|
||||
CLKDEV_CON_ID("ohci_clk", &uhphs_clk),
|
||||
CLKDEV_CON_DEV_ID("ehci_clk", "atmel-ehci.0", &uhphs_clk),
|
||||
CLKDEV_CON_DEV_ID("hclk", "atmel_usba_udc.0", &utmi_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "atmel_usba_udc.0", &udphs_clk),
|
||||
CLKDEV_CON_DEV_ID("mci_clk", "at91_mci.0", &mmc0_clk),
|
||||
CLKDEV_CON_DEV_ID("mci_clk", "at91_mci.1", &mmc1_clk),
|
||||
CLKDEV_CON_DEV_ID("ehci_clk", "atmel-ehci", &uhphs_clk),
|
||||
CLKDEV_CON_DEV_ID("hclk", "atmel_usba_udc", &utmi_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "atmel_usba_udc", &udphs_clk),
|
||||
CLKDEV_CON_DEV_ID("mci_clk", "atmel_mci.0", &mmc0_clk),
|
||||
CLKDEV_CON_DEV_ID("mci_clk", "atmel_mci.1", &mmc1_clk),
|
||||
CLKDEV_CON_DEV_ID("spi_clk", "atmel_spi.0", &spi0_clk),
|
||||
CLKDEV_CON_DEV_ID("spi_clk", "atmel_spi.1", &spi1_clk),
|
||||
CLKDEV_CON_DEV_ID("t0_clk", "atmel_tcb.0", &tcb0_clk),
|
||||
|
@ -1550,7 +1550,7 @@ void __init at91_set_serial_console(unsigned portnr)
|
||||
{
|
||||
if (portnr < ATMEL_MAX_UART) {
|
||||
atmel_default_console_device = at91_uarts[portnr];
|
||||
at91sam9g45_set_console_clock(portnr);
|
||||
at91sam9g45_set_console_clock(at91_uarts[portnr]->id);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -191,8 +191,8 @@ static struct clk *periph_clocks[] __initdata = {
|
||||
};
|
||||
|
||||
static struct clk_lookup periph_clocks_lookups[] = {
|
||||
CLKDEV_CON_DEV_ID("hclk", "atmel_usba_udc.0", &utmi_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "atmel_usba_udc.0", &udphs_clk),
|
||||
CLKDEV_CON_DEV_ID("hclk", "atmel_usba_udc", &utmi_clk),
|
||||
CLKDEV_CON_DEV_ID("pclk", "atmel_usba_udc", &udphs_clk),
|
||||
CLKDEV_CON_DEV_ID("t0_clk", "atmel_tcb.0", &tc0_clk),
|
||||
CLKDEV_CON_DEV_ID("t1_clk", "atmel_tcb.0", &tc1_clk),
|
||||
CLKDEV_CON_DEV_ID("t2_clk", "atmel_tcb.0", &tc2_clk),
|
||||
|
@ -1168,7 +1168,7 @@ void __init at91_set_serial_console(unsigned portnr)
|
||||
{
|
||||
if (portnr < ATMEL_MAX_UART) {
|
||||
atmel_default_console_device = at91_uarts[portnr];
|
||||
at91sam9rl_set_console_clock(portnr);
|
||||
at91sam9rl_set_console_clock(at91_uarts[portnr]->id);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -215,7 +215,7 @@ static void __init cap9adk_add_device_nand(void)
|
||||
csa = at91_sys_read(AT91_MATRIX_EBICSA);
|
||||
at91_sys_write(AT91_MATRIX_EBICSA, csa | AT91_MATRIX_EBI_VDDIOMSEL_3_3V);
|
||||
|
||||
cap9adk_nand_data.bus_width_16 = !board_have_nand_8bit();
|
||||
cap9adk_nand_data.bus_width_16 = board_have_nand_16bit();
|
||||
/* setup bus-width (8 or 16) */
|
||||
if (cap9adk_nand_data.bus_width_16)
|
||||
cap9adk_nand_smc_config.mode |= AT91_SMC_DBW_16;
|
||||
|
@ -214,7 +214,7 @@ static struct sam9_smc_config __initdata ek_nand_smc_config = {
|
||||
|
||||
static void __init ek_add_device_nand(void)
|
||||
{
|
||||
ek_nand_data.bus_width_16 = !board_have_nand_8bit();
|
||||
ek_nand_data.bus_width_16 = board_have_nand_16bit();
|
||||
/* setup bus-width (8 or 16) */
|
||||
if (ek_nand_data.bus_width_16)
|
||||
ek_nand_smc_config.mode |= AT91_SMC_DBW_16;
|
||||
|
@ -220,7 +220,7 @@ static struct sam9_smc_config __initdata ek_nand_smc_config = {
|
||||
|
||||
static void __init ek_add_device_nand(void)
|
||||
{
|
||||
ek_nand_data.bus_width_16 = !board_have_nand_8bit();
|
||||
ek_nand_data.bus_width_16 = board_have_nand_16bit();
|
||||
/* setup bus-width (8 or 16) */
|
||||
if (ek_nand_data.bus_width_16)
|
||||
ek_nand_smc_config.mode |= AT91_SMC_DBW_16;
|
||||
|
@ -221,7 +221,7 @@ static struct sam9_smc_config __initdata ek_nand_smc_config = {
|
||||
|
||||
static void __init ek_add_device_nand(void)
|
||||
{
|
||||
ek_nand_data.bus_width_16 = !board_have_nand_8bit();
|
||||
ek_nand_data.bus_width_16 = board_have_nand_16bit();
|
||||
/* setup bus-width (8 or 16) */
|
||||
if (ek_nand_data.bus_width_16)
|
||||
ek_nand_smc_config.mode |= AT91_SMC_DBW_16;
|
||||
|
@ -198,7 +198,7 @@ static struct sam9_smc_config __initdata ek_nand_smc_config = {
|
||||
|
||||
static void __init ek_add_device_nand(void)
|
||||
{
|
||||
ek_nand_data.bus_width_16 = !board_have_nand_8bit();
|
||||
ek_nand_data.bus_width_16 = board_have_nand_16bit();
|
||||
/* setup bus-width (8 or 16) */
|
||||
if (ek_nand_data.bus_width_16)
|
||||
ek_nand_smc_config.mode |= AT91_SMC_DBW_16;
|
||||
|
@ -178,7 +178,7 @@ static struct sam9_smc_config __initdata ek_nand_smc_config = {
|
||||
|
||||
static void __init ek_add_device_nand(void)
|
||||
{
|
||||
ek_nand_data.bus_width_16 = !board_have_nand_8bit();
|
||||
ek_nand_data.bus_width_16 = board_have_nand_16bit();
|
||||
/* setup bus-width (8 or 16) */
|
||||
if (ek_nand_data.bus_width_16)
|
||||
ek_nand_smc_config.mode |= AT91_SMC_DBW_16;
|
||||
|
@ -13,13 +13,13 @@
|
||||
* the 16-31 bit are reserved for at91 generic information
|
||||
*
|
||||
* bit 31:
|
||||
* 0 => nand 16 bit
|
||||
* 1 => nand 8 bit
|
||||
* 0 => nand 8 bit
|
||||
* 1 => nand 16 bit
|
||||
*/
|
||||
#define BOARD_HAVE_NAND_8BIT (1 << 31)
|
||||
static int inline board_have_nand_8bit(void)
|
||||
#define BOARD_HAVE_NAND_16BIT (1 << 31)
|
||||
static inline int board_have_nand_16bit(void)
|
||||
{
|
||||
return system_rev & BOARD_HAVE_NAND_8BIT;
|
||||
return system_rev & BOARD_HAVE_NAND_16BIT;
|
||||
}
|
||||
|
||||
#endif /* __ARCH_SYSTEM_REV_H__ */
|
||||
|
@ -53,7 +53,7 @@ davinci_alloc_gc(void __iomem *base, unsigned int irq_start, unsigned int num)
|
||||
|
||||
gc = irq_alloc_generic_chip("AINTC", 1, irq_start, base, handle_edge_irq);
|
||||
ct = gc->chip_types;
|
||||
ct->chip.irq_ack = irq_gc_ack;
|
||||
ct->chip.irq_ack = irq_gc_ack_set_bit;
|
||||
ct->chip.irq_mask = irq_gc_mask_clr_bit;
|
||||
ct->chip.irq_unmask = irq_gc_mask_set_bit;
|
||||
|
||||
|
@ -251,9 +251,9 @@ static void ep93xx_uart_set_mctrl(struct amba_device *dev,
|
||||
unsigned int mcr;
|
||||
|
||||
mcr = 0;
|
||||
if (!(mctrl & TIOCM_RTS))
|
||||
if (mctrl & TIOCM_RTS)
|
||||
mcr |= 2;
|
||||
if (!(mctrl & TIOCM_DTR))
|
||||
if (mctrl & TIOCM_DTR)
|
||||
mcr |= 1;
|
||||
|
||||
__raw_writel(mcr, base + EP93XX_UART_MCR_OFFSET);
|
||||
|
@ -23,6 +23,7 @@
|
||||
#include <plat/sdhci.h>
|
||||
#include <plat/devs.h>
|
||||
#include <plat/fimc-core.h>
|
||||
#include <plat/iic-core.h>
|
||||
|
||||
#include <mach/regs-irq.h>
|
||||
|
||||
@ -132,6 +133,11 @@ void __init exynos4_map_io(void)
|
||||
s3c_fimc_setname(1, "exynos4-fimc");
|
||||
s3c_fimc_setname(2, "exynos4-fimc");
|
||||
s3c_fimc_setname(3, "exynos4-fimc");
|
||||
|
||||
/* The I2C bus controllers are directly compatible with s3c2440 */
|
||||
s3c_i2c0_setname("s3c2440-i2c");
|
||||
s3c_i2c1_setname("s3c2440-i2c");
|
||||
s3c_i2c2_setname("s3c2440-i2c");
|
||||
}
|
||||
|
||||
void __init exynos4_init_clocks(int xtal)
|
||||
|
@ -330,7 +330,7 @@ struct platform_device exynos4_device_ac97 = {
|
||||
|
||||
static int exynos4_spdif_cfg_gpio(struct platform_device *pdev)
|
||||
{
|
||||
s3c_gpio_cfgpin_range(EXYNOS4_GPC1(0), 2, S3C_GPIO_SFN(3));
|
||||
s3c_gpio_cfgpin_range(EXYNOS4_GPC1(0), 2, S3C_GPIO_SFN(4));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -13,7 +13,7 @@
|
||||
#include <linux/linkage.h>
|
||||
#include <linux/init.h>
|
||||
|
||||
__INIT
|
||||
__CPUINIT
|
||||
|
||||
/*
|
||||
* exynos4 specific entry point for secondary CPUs. This provides
|
||||
|
@ -78,9 +78,7 @@ static struct s3c2410_uartcfg smdkv310_uartcfgs[] __initdata = {
|
||||
};
|
||||
|
||||
static struct s3c_sdhci_platdata smdkv310_hsmmc0_pdata __initdata = {
|
||||
.cd_type = S3C_SDHCI_CD_GPIO,
|
||||
.ext_cd_gpio = EXYNOS4_GPK0(2),
|
||||
.ext_cd_gpio_invert = 1,
|
||||
.cd_type = S3C_SDHCI_CD_INTERNAL,
|
||||
.clk_type = S3C_SDHCI_CLK_DIV_EXTERNAL,
|
||||
#ifdef CONFIG_EXYNOS4_SDHCI_CH0_8BIT
|
||||
.max_width = 8,
|
||||
@ -96,9 +94,7 @@ static struct s3c_sdhci_platdata smdkv310_hsmmc1_pdata __initdata = {
|
||||
};
|
||||
|
||||
static struct s3c_sdhci_platdata smdkv310_hsmmc2_pdata __initdata = {
|
||||
.cd_type = S3C_SDHCI_CD_GPIO,
|
||||
.ext_cd_gpio = EXYNOS4_GPK2(2),
|
||||
.ext_cd_gpio_invert = 1,
|
||||
.cd_type = S3C_SDHCI_CD_INTERNAL,
|
||||
.clk_type = S3C_SDHCI_CLK_DIV_EXTERNAL,
|
||||
#ifdef CONFIG_EXYNOS4_SDHCI_CH2_8BIT
|
||||
.max_width = 8,
|
||||
|
@ -79,7 +79,7 @@ static APBC_CLK(ssp4, PXA168_SSP4, 4, 0);
|
||||
static APBC_CLK(ssp5, PXA168_SSP5, 4, 0);
|
||||
static APBC_CLK(keypad, PXA168_KPC, 0, 32000);
|
||||
|
||||
static APMU_CLK(nand, NAND, 0x01db, 208000000);
|
||||
static APMU_CLK(nand, NAND, 0x19b, 156000000);
|
||||
static APMU_CLK(lcd, LCD, 0x7f, 312000000);
|
||||
|
||||
/* device and clock bindings */
|
||||
|
@ -110,7 +110,7 @@ static APBC_CLK(pwm2, PXA910_PWM2, 1, 13000000);
|
||||
static APBC_CLK(pwm3, PXA910_PWM3, 1, 13000000);
|
||||
static APBC_CLK(pwm4, PXA910_PWM4, 1, 13000000);
|
||||
|
||||
static APMU_CLK(nand, NAND, 0x01db, 208000000);
|
||||
static APMU_CLK(nand, NAND, 0x19b, 156000000);
|
||||
static APMU_CLK(u2o, USB, 0x1b, 480000000);
|
||||
|
||||
/* device and clock bindings */
|
||||
|
@ -215,7 +215,7 @@ static struct omap_kp_platform_data ams_delta_kp_data __initdata = {
|
||||
.delay = 9,
|
||||
};
|
||||
|
||||
static struct platform_device ams_delta_kp_device __initdata = {
|
||||
static struct platform_device ams_delta_kp_device = {
|
||||
.name = "omap-keypad",
|
||||
.id = -1,
|
||||
.dev = {
|
||||
@ -225,12 +225,12 @@ static struct platform_device ams_delta_kp_device __initdata = {
|
||||
.resource = ams_delta_kp_resources,
|
||||
};
|
||||
|
||||
static struct platform_device ams_delta_lcd_device __initdata = {
|
||||
static struct platform_device ams_delta_lcd_device = {
|
||||
.name = "lcd_ams_delta",
|
||||
.id = -1,
|
||||
};
|
||||
|
||||
static struct platform_device ams_delta_led_device __initdata = {
|
||||
static struct platform_device ams_delta_led_device = {
|
||||
.name = "ams-delta-led",
|
||||
.id = -1
|
||||
};
|
||||
@ -267,7 +267,7 @@ static struct soc_camera_link ams_delta_iclink = {
|
||||
.power = ams_delta_camera_power,
|
||||
};
|
||||
|
||||
static struct platform_device ams_delta_camera_device __initdata = {
|
||||
static struct platform_device ams_delta_camera_device = {
|
||||
.name = "soc-camera-pdrv",
|
||||
.id = 0,
|
||||
.dev = {
|
||||
|
@ -41,7 +41,7 @@ static struct __initdata omap_gpio_platform_data omap15xx_mpu_gpio_config = {
|
||||
.bank_stride = 1,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap15xx_mpu_gpio = {
|
||||
static struct platform_device omap15xx_mpu_gpio = {
|
||||
.name = "omap_gpio",
|
||||
.id = 0,
|
||||
.dev = {
|
||||
@ -70,7 +70,7 @@ static struct __initdata omap_gpio_platform_data omap15xx_gpio_config = {
|
||||
.bank_width = 16,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap15xx_gpio = {
|
||||
static struct platform_device omap15xx_gpio = {
|
||||
.name = "omap_gpio",
|
||||
.id = 1,
|
||||
.dev = {
|
||||
|
@ -44,7 +44,7 @@ static struct __initdata omap_gpio_platform_data omap16xx_mpu_gpio_config = {
|
||||
.bank_stride = 1,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap16xx_mpu_gpio = {
|
||||
static struct platform_device omap16xx_mpu_gpio = {
|
||||
.name = "omap_gpio",
|
||||
.id = 0,
|
||||
.dev = {
|
||||
@ -73,7 +73,7 @@ static struct __initdata omap_gpio_platform_data omap16xx_gpio1_config = {
|
||||
.bank_width = 16,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap16xx_gpio1 = {
|
||||
static struct platform_device omap16xx_gpio1 = {
|
||||
.name = "omap_gpio",
|
||||
.id = 1,
|
||||
.dev = {
|
||||
@ -102,7 +102,7 @@ static struct __initdata omap_gpio_platform_data omap16xx_gpio2_config = {
|
||||
.bank_width = 16,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap16xx_gpio2 = {
|
||||
static struct platform_device omap16xx_gpio2 = {
|
||||
.name = "omap_gpio",
|
||||
.id = 2,
|
||||
.dev = {
|
||||
@ -131,7 +131,7 @@ static struct __initdata omap_gpio_platform_data omap16xx_gpio3_config = {
|
||||
.bank_width = 16,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap16xx_gpio3 = {
|
||||
static struct platform_device omap16xx_gpio3 = {
|
||||
.name = "omap_gpio",
|
||||
.id = 3,
|
||||
.dev = {
|
||||
@ -160,7 +160,7 @@ static struct __initdata omap_gpio_platform_data omap16xx_gpio4_config = {
|
||||
.bank_width = 16,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap16xx_gpio4 = {
|
||||
static struct platform_device omap16xx_gpio4 = {
|
||||
.name = "omap_gpio",
|
||||
.id = 4,
|
||||
.dev = {
|
||||
|
@ -46,7 +46,7 @@ static struct __initdata omap_gpio_platform_data omap7xx_mpu_gpio_config = {
|
||||
.bank_stride = 2,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap7xx_mpu_gpio = {
|
||||
static struct platform_device omap7xx_mpu_gpio = {
|
||||
.name = "omap_gpio",
|
||||
.id = 0,
|
||||
.dev = {
|
||||
@ -75,7 +75,7 @@ static struct __initdata omap_gpio_platform_data omap7xx_gpio1_config = {
|
||||
.bank_width = 32,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap7xx_gpio1 = {
|
||||
static struct platform_device omap7xx_gpio1 = {
|
||||
.name = "omap_gpio",
|
||||
.id = 1,
|
||||
.dev = {
|
||||
@ -104,7 +104,7 @@ static struct __initdata omap_gpio_platform_data omap7xx_gpio2_config = {
|
||||
.bank_width = 32,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap7xx_gpio2 = {
|
||||
static struct platform_device omap7xx_gpio2 = {
|
||||
.name = "omap_gpio",
|
||||
.id = 2,
|
||||
.dev = {
|
||||
@ -133,7 +133,7 @@ static struct __initdata omap_gpio_platform_data omap7xx_gpio3_config = {
|
||||
.bank_width = 32,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap7xx_gpio3 = {
|
||||
static struct platform_device omap7xx_gpio3 = {
|
||||
.name = "omap_gpio",
|
||||
.id = 3,
|
||||
.dev = {
|
||||
@ -162,7 +162,7 @@ static struct __initdata omap_gpio_platform_data omap7xx_gpio4_config = {
|
||||
.bank_width = 32,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap7xx_gpio4 = {
|
||||
static struct platform_device omap7xx_gpio4 = {
|
||||
.name = "omap_gpio",
|
||||
.id = 4,
|
||||
.dev = {
|
||||
@ -191,7 +191,7 @@ static struct __initdata omap_gpio_platform_data omap7xx_gpio5_config = {
|
||||
.bank_width = 32,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap7xx_gpio5 = {
|
||||
static struct platform_device omap7xx_gpio5 = {
|
||||
.name = "omap_gpio",
|
||||
.id = 5,
|
||||
.dev = {
|
||||
@ -220,7 +220,7 @@ static struct __initdata omap_gpio_platform_data omap7xx_gpio6_config = {
|
||||
.bank_width = 32,
|
||||
};
|
||||
|
||||
static struct __initdata platform_device omap7xx_gpio6 = {
|
||||
static struct platform_device omap7xx_gpio6 = {
|
||||
.name = "omap_gpio",
|
||||
.id = 6,
|
||||
.dev = {
|
||||
|
@ -558,7 +558,7 @@ static struct radio_si4713_platform_data rx51_si4713_data __initdata_or_module =
|
||||
.subdev_board_info = &rx51_si4713_board_info,
|
||||
};
|
||||
|
||||
static struct platform_device rx51_si4713_dev __initdata_or_module = {
|
||||
static struct platform_device rx51_si4713_dev = {
|
||||
.name = "radio-si4713",
|
||||
.id = -1,
|
||||
.dev = {
|
||||
|
@ -347,9 +347,9 @@ static int pxa2xx_mfp_suspend(void)
|
||||
if ((gpio_desc[i].config & MFP_LPM_KEEP_OUTPUT) &&
|
||||
(GPDR(i) & GPIO_bit(i))) {
|
||||
if (GPLR(i) & GPIO_bit(i))
|
||||
PGSR(i) |= GPIO_bit(i);
|
||||
PGSR(gpio_to_bank(i)) |= GPIO_bit(i);
|
||||
else
|
||||
PGSR(i) &= ~GPIO_bit(i);
|
||||
PGSR(gpio_to_bank(i)) &= ~GPIO_bit(i);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -573,10 +573,10 @@ static struct pxafb_mode_info sharp_lq043t3dx02_mode = {
|
||||
.xres = 480,
|
||||
.yres = 272,
|
||||
.bpp = 16,
|
||||
.hsync_len = 4,
|
||||
.hsync_len = 41,
|
||||
.left_margin = 2,
|
||||
.right_margin = 1,
|
||||
.vsync_len = 1,
|
||||
.vsync_len = 10,
|
||||
.upper_margin = 3,
|
||||
.lower_margin = 1,
|
||||
.sync = 0,
|
||||
@ -596,29 +596,31 @@ static void __init raumfeld_lcd_init(void)
|
||||
{
|
||||
int ret;
|
||||
|
||||
pxa_set_fb_info(NULL, &raumfeld_sharp_lcd_info);
|
||||
|
||||
/* Earlier devices had the backlight regulator controlled
|
||||
* via PWM, later versions use another controller for that */
|
||||
if ((system_rev & 0xff) < 2) {
|
||||
mfp_cfg_t raumfeld_pwm_pin_config = GPIO17_PWM0_OUT;
|
||||
pxa3xx_mfp_config(&raumfeld_pwm_pin_config, 1);
|
||||
platform_device_register(&raumfeld_pwm_backlight_device);
|
||||
} else
|
||||
platform_device_register(&raumfeld_lt3593_device);
|
||||
|
||||
ret = gpio_request(GPIO_TFT_VA_EN, "display VA enable");
|
||||
if (ret < 0)
|
||||
pr_warning("Unable to request GPIO_TFT_VA_EN\n");
|
||||
else
|
||||
gpio_direction_output(GPIO_TFT_VA_EN, 1);
|
||||
|
||||
msleep(100);
|
||||
|
||||
ret = gpio_request(GPIO_DISPLAY_ENABLE, "display enable");
|
||||
if (ret < 0)
|
||||
pr_warning("Unable to request GPIO_DISPLAY_ENABLE\n");
|
||||
else
|
||||
gpio_direction_output(GPIO_DISPLAY_ENABLE, 1);
|
||||
|
||||
/* Hardware revision 2 has the backlight regulator controlled
|
||||
* by an LT3593, earlier and later devices use PWM for that. */
|
||||
if ((system_rev & 0xff) == 2) {
|
||||
platform_device_register(&raumfeld_lt3593_device);
|
||||
} else {
|
||||
mfp_cfg_t raumfeld_pwm_pin_config = GPIO17_PWM0_OUT;
|
||||
pxa3xx_mfp_config(&raumfeld_pwm_pin_config, 1);
|
||||
platform_device_register(&raumfeld_pwm_backlight_device);
|
||||
}
|
||||
|
||||
pxa_set_fb_info(NULL, &raumfeld_sharp_lcd_info);
|
||||
platform_device_register(&pxa3xx_device_gcu);
|
||||
}
|
||||
|
||||
@ -657,10 +659,10 @@ static struct lis3lv02d_platform_data lis3_pdata = {
|
||||
|
||||
#define SPI_AK4104 \
|
||||
{ \
|
||||
.modalias = "ak4104", \
|
||||
.max_speed_hz = 10000, \
|
||||
.bus_num = 0, \
|
||||
.chip_select = 0, \
|
||||
.modalias = "ak4104-codec", \
|
||||
.max_speed_hz = 10000, \
|
||||
.bus_num = 0, \
|
||||
.chip_select = 0, \
|
||||
.controller_data = (void *) GPIO_SPDIF_CS, \
|
||||
}
|
||||
|
||||
|
@ -552,7 +552,7 @@ struct mini2440_features_t {
|
||||
struct platform_device *optional[8];
|
||||
};
|
||||
|
||||
static void mini2440_parse_features(
|
||||
static void __init mini2440_parse_features(
|
||||
struct mini2440_features_t * features,
|
||||
const char * features_str )
|
||||
{
|
||||
|
@ -88,6 +88,7 @@ static struct s3c64xx_spi_info s3c64xx_spi0_pdata = {
|
||||
.cfg_gpio = s3c64xx_spi_cfg_gpio,
|
||||
.fifo_lvl_mask = 0x7f,
|
||||
.rx_lvl_offset = 13,
|
||||
.tx_st_done = 21,
|
||||
};
|
||||
|
||||
static u64 spi_dmamask = DMA_BIT_MASK(32);
|
||||
@ -132,6 +133,7 @@ static struct s3c64xx_spi_info s3c64xx_spi1_pdata = {
|
||||
.cfg_gpio = s3c64xx_spi_cfg_gpio,
|
||||
.fifo_lvl_mask = 0x7f,
|
||||
.rx_lvl_offset = 13,
|
||||
.tx_st_done = 21,
|
||||
};
|
||||
|
||||
struct platform_device s3c64xx_device_spi1 = {
|
||||
|
@ -112,12 +112,14 @@ static struct s3c64xx_spi_info s5p6440_spi0_pdata = {
|
||||
.cfg_gpio = s5p6440_spi_cfg_gpio,
|
||||
.fifo_lvl_mask = 0x1ff,
|
||||
.rx_lvl_offset = 15,
|
||||
.tx_st_done = 25,
|
||||
};
|
||||
|
||||
static struct s3c64xx_spi_info s5p6450_spi0_pdata = {
|
||||
.cfg_gpio = s5p6450_spi_cfg_gpio,
|
||||
.fifo_lvl_mask = 0x1ff,
|
||||
.rx_lvl_offset = 15,
|
||||
.tx_st_done = 25,
|
||||
};
|
||||
|
||||
static u64 spi_dmamask = DMA_BIT_MASK(32);
|
||||
@ -160,12 +162,14 @@ static struct s3c64xx_spi_info s5p6440_spi1_pdata = {
|
||||
.cfg_gpio = s5p6440_spi_cfg_gpio,
|
||||
.fifo_lvl_mask = 0x7f,
|
||||
.rx_lvl_offset = 15,
|
||||
.tx_st_done = 25,
|
||||
};
|
||||
|
||||
static struct s3c64xx_spi_info s5p6450_spi1_pdata = {
|
||||
.cfg_gpio = s5p6450_spi_cfg_gpio,
|
||||
.fifo_lvl_mask = 0x7f,
|
||||
.rx_lvl_offset = 15,
|
||||
.tx_st_done = 25,
|
||||
};
|
||||
|
||||
struct platform_device s5p64x0_device_spi1 = {
|
||||
|
@ -15,6 +15,7 @@
|
||||
#include <mach/dma.h>
|
||||
#include <mach/map.h>
|
||||
#include <mach/spi-clocks.h>
|
||||
#include <mach/irqs.h>
|
||||
|
||||
#include <plat/s3c64xx-spi.h>
|
||||
#include <plat/gpio-cfg.h>
|
||||
@ -90,6 +91,7 @@ static struct s3c64xx_spi_info s5pc100_spi0_pdata = {
|
||||
.fifo_lvl_mask = 0x7f,
|
||||
.rx_lvl_offset = 13,
|
||||
.high_speed = 1,
|
||||
.tx_st_done = 21,
|
||||
};
|
||||
|
||||
static u64 spi_dmamask = DMA_BIT_MASK(32);
|
||||
@ -134,6 +136,7 @@ static struct s3c64xx_spi_info s5pc100_spi1_pdata = {
|
||||
.fifo_lvl_mask = 0x7f,
|
||||
.rx_lvl_offset = 13,
|
||||
.high_speed = 1,
|
||||
.tx_st_done = 21,
|
||||
};
|
||||
|
||||
struct platform_device s5pc100_device_spi1 = {
|
||||
@ -176,6 +179,7 @@ static struct s3c64xx_spi_info s5pc100_spi2_pdata = {
|
||||
.fifo_lvl_mask = 0x7f,
|
||||
.rx_lvl_offset = 13,
|
||||
.high_speed = 1,
|
||||
.tx_st_done = 21,
|
||||
};
|
||||
|
||||
struct platform_device s5pc100_device_spi2 = {
|
||||
|
@ -85,6 +85,7 @@ static struct s3c64xx_spi_info s5pv210_spi0_pdata = {
|
||||
.fifo_lvl_mask = 0x1ff,
|
||||
.rx_lvl_offset = 15,
|
||||
.high_speed = 1,
|
||||
.tx_st_done = 25,
|
||||
};
|
||||
|
||||
static u64 spi_dmamask = DMA_BIT_MASK(32);
|
||||
@ -129,6 +130,7 @@ static struct s3c64xx_spi_info s5pv210_spi1_pdata = {
|
||||
.fifo_lvl_mask = 0x7f,
|
||||
.rx_lvl_offset = 15,
|
||||
.high_speed = 1,
|
||||
.tx_st_done = 25,
|
||||
};
|
||||
|
||||
struct platform_device s5pv210_device_spi1 = {
|
||||
|
@ -39,9 +39,10 @@
|
||||
static void __iomem *ic_regbase;
|
||||
static void __iomem *sic_regbase;
|
||||
|
||||
static void vt8500_irq_mask(unsigned int irq)
|
||||
static void vt8500_irq_mask(struct irq_data *d)
|
||||
{
|
||||
void __iomem *base = ic_regbase;
|
||||
unsigned irq = d->irq;
|
||||
u8 edge;
|
||||
|
||||
if (irq >= 64) {
|
||||
@ -64,9 +65,10 @@ static void vt8500_irq_mask(unsigned int irq)
|
||||
}
|
||||
}
|
||||
|
||||
static void vt8500_irq_unmask(unsigned int irq)
|
||||
static void vt8500_irq_unmask(struct irq_data *d)
|
||||
{
|
||||
void __iomem *base = ic_regbase;
|
||||
unsigned irq = d->irq;
|
||||
u8 dctr;
|
||||
|
||||
if (irq >= 64) {
|
||||
@ -78,10 +80,11 @@ static void vt8500_irq_unmask(unsigned int irq)
|
||||
writeb(dctr, base + VT8500_IC_DCTR + irq);
|
||||
}
|
||||
|
||||
static int vt8500_irq_set_type(unsigned int irq, unsigned int flow_type)
|
||||
static int vt8500_irq_set_type(struct irq_data *d, unsigned int flow_type)
|
||||
{
|
||||
void __iomem *base = ic_regbase;
|
||||
unsigned int orig_irq = irq;
|
||||
unsigned irq = d->irq;
|
||||
unsigned orig_irq = irq;
|
||||
u8 dctr;
|
||||
|
||||
if (irq >= 64) {
|
||||
@ -114,11 +117,11 @@ static int vt8500_irq_set_type(unsigned int irq, unsigned int flow_type)
|
||||
}
|
||||
|
||||
static struct irq_chip vt8500_irq_chip = {
|
||||
.name = "vt8500",
|
||||
.ack = vt8500_irq_mask,
|
||||
.mask = vt8500_irq_mask,
|
||||
.unmask = vt8500_irq_unmask,
|
||||
.set_type = vt8500_irq_set_type,
|
||||
.name = "vt8500",
|
||||
.irq_ack = vt8500_irq_mask,
|
||||
.irq_mask = vt8500_irq_mask,
|
||||
.irq_unmask = vt8500_irq_unmask,
|
||||
.irq_set_type = vt8500_irq_set_type,
|
||||
};
|
||||
|
||||
void __init vt8500_init_irq(void)
|
||||
|
@ -120,17 +120,22 @@ static void l2x0_cache_sync(void)
|
||||
spin_unlock_irqrestore(&l2x0_lock, flags);
|
||||
}
|
||||
|
||||
static void __l2x0_flush_all(void)
|
||||
{
|
||||
debug_writel(0x03);
|
||||
writel_relaxed(l2x0_way_mask, l2x0_base + L2X0_CLEAN_INV_WAY);
|
||||
cache_wait_way(l2x0_base + L2X0_CLEAN_INV_WAY, l2x0_way_mask);
|
||||
cache_sync();
|
||||
debug_writel(0x00);
|
||||
}
|
||||
|
||||
static void l2x0_flush_all(void)
|
||||
{
|
||||
unsigned long flags;
|
||||
|
||||
/* clean all ways */
|
||||
spin_lock_irqsave(&l2x0_lock, flags);
|
||||
debug_writel(0x03);
|
||||
writel_relaxed(l2x0_way_mask, l2x0_base + L2X0_CLEAN_INV_WAY);
|
||||
cache_wait_way(l2x0_base + L2X0_CLEAN_INV_WAY, l2x0_way_mask);
|
||||
cache_sync();
|
||||
debug_writel(0x00);
|
||||
__l2x0_flush_all();
|
||||
spin_unlock_irqrestore(&l2x0_lock, flags);
|
||||
}
|
||||
|
||||
@ -266,7 +271,9 @@ static void l2x0_disable(void)
|
||||
unsigned long flags;
|
||||
|
||||
spin_lock_irqsave(&l2x0_lock, flags);
|
||||
writel(0, l2x0_base + L2X0_CTRL);
|
||||
__l2x0_flush_all();
|
||||
writel_relaxed(0, l2x0_base + L2X0_CTRL);
|
||||
dsb();
|
||||
spin_unlock_irqrestore(&l2x0_lock, flags);
|
||||
}
|
||||
|
||||
|
@ -759,7 +759,7 @@ early_param("vmalloc", early_vmalloc);
|
||||
|
||||
static phys_addr_t lowmem_limit __initdata = 0;
|
||||
|
||||
static void __init sanity_check_meminfo(void)
|
||||
void __init sanity_check_meminfo(void)
|
||||
{
|
||||
int i, j, highmem = 0;
|
||||
|
||||
@ -1032,8 +1032,9 @@ void __init paging_init(struct machine_desc *mdesc)
|
||||
{
|
||||
void *zero_page;
|
||||
|
||||
memblock_set_current_limit(lowmem_limit);
|
||||
|
||||
build_mem_type_table();
|
||||
sanity_check_meminfo();
|
||||
prepare_page_table();
|
||||
map_lowmem();
|
||||
devicemaps_init(mdesc);
|
||||
|
@ -27,6 +27,10 @@ void __init arm_mm_memblock_reserve(void)
|
||||
memblock_reserve(CONFIG_VECTORS_BASE, PAGE_SIZE);
|
||||
}
|
||||
|
||||
void __init sanity_check_meminfo(void)
|
||||
{
|
||||
}
|
||||
|
||||
/*
|
||||
* paging_init() sets up the page tables, initialises the zone memory
|
||||
* maps, and sets up the zero page, bad page and bad page tables.
|
||||
|
@ -432,7 +432,7 @@ void __init orion_gpio_init(int gpio_base, int ngpio,
|
||||
ct->regs.mask = ochip->mask_offset + GPIO_EDGE_MASK_OFF;
|
||||
ct->regs.ack = GPIO_EDGE_CAUSE_OFF;
|
||||
ct->type = IRQ_TYPE_EDGE_RISING | IRQ_TYPE_EDGE_FALLING;
|
||||
ct->chip.irq_ack = irq_gc_ack;
|
||||
ct->chip.irq_ack = irq_gc_ack_clr_bit;
|
||||
ct->chip.irq_mask = irq_gc_mask_clr_bit;
|
||||
ct->chip.irq_unmask = irq_gc_mask_set_bit;
|
||||
ct->chip.irq_set_type = gpio_irq_set_type;
|
||||
|
@ -50,7 +50,7 @@ static inline void __iomem *gpio_chip_base(struct gpio_chip *c)
|
||||
return container_of(c, struct pxa_gpio_chip, chip)->regbase;
|
||||
}
|
||||
|
||||
static inline struct pxa_gpio_chip *gpio_to_chip(unsigned gpio)
|
||||
static inline struct pxa_gpio_chip *gpio_to_pxachip(unsigned gpio)
|
||||
{
|
||||
return &pxa_gpio_chips[gpio_to_bank(gpio)];
|
||||
}
|
||||
@ -161,7 +161,7 @@ static int pxa_gpio_irq_type(struct irq_data *d, unsigned int type)
|
||||
int gpio = irq_to_gpio(d->irq);
|
||||
unsigned long gpdr, mask = GPIO_bit(gpio);
|
||||
|
||||
c = gpio_to_chip(gpio);
|
||||
c = gpio_to_pxachip(gpio);
|
||||
|
||||
if (type == IRQ_TYPE_PROBE) {
|
||||
/* Don't mess with enabled GPIOs using preconfigured edges or
|
||||
@ -230,7 +230,7 @@ static void pxa_gpio_demux_handler(unsigned int irq, struct irq_desc *desc)
|
||||
static void pxa_ack_muxed_gpio(struct irq_data *d)
|
||||
{
|
||||
int gpio = irq_to_gpio(d->irq);
|
||||
struct pxa_gpio_chip *c = gpio_to_chip(gpio);
|
||||
struct pxa_gpio_chip *c = gpio_to_pxachip(gpio);
|
||||
|
||||
__raw_writel(GPIO_bit(gpio), c->regbase + GEDR_OFFSET);
|
||||
}
|
||||
@ -238,7 +238,7 @@ static void pxa_ack_muxed_gpio(struct irq_data *d)
|
||||
static void pxa_mask_muxed_gpio(struct irq_data *d)
|
||||
{
|
||||
int gpio = irq_to_gpio(d->irq);
|
||||
struct pxa_gpio_chip *c = gpio_to_chip(gpio);
|
||||
struct pxa_gpio_chip *c = gpio_to_pxachip(gpio);
|
||||
uint32_t grer, gfer;
|
||||
|
||||
c->irq_mask &= ~GPIO_bit(gpio);
|
||||
@ -252,7 +252,7 @@ static void pxa_mask_muxed_gpio(struct irq_data *d)
|
||||
static void pxa_unmask_muxed_gpio(struct irq_data *d)
|
||||
{
|
||||
int gpio = irq_to_gpio(d->irq);
|
||||
struct pxa_gpio_chip *c = gpio_to_chip(gpio);
|
||||
struct pxa_gpio_chip *c = gpio_to_pxachip(gpio);
|
||||
|
||||
c->irq_mask |= GPIO_bit(gpio);
|
||||
update_edge_detect(c);
|
||||
|
@ -1027,17 +1027,13 @@ int s3c2410_dma_config(unsigned int channel,
|
||||
struct s3c2410_dma_chan *chan = s3c_dma_lookup_channel(channel);
|
||||
unsigned int dcon;
|
||||
|
||||
pr_debug("%s: chan=%d, xfer_unit=%d, dcon=%08x\n",
|
||||
__func__, channel, xferunit, dcon);
|
||||
pr_debug("%s: chan=%d, xfer_unit=%d\n", __func__, channel, xferunit);
|
||||
|
||||
if (chan == NULL)
|
||||
return -EINVAL;
|
||||
|
||||
pr_debug("%s: Initial dcon is %08x\n", __func__, dcon);
|
||||
|
||||
dcon = chan->dcon & dma_sel.dcon_mask;
|
||||
|
||||
pr_debug("%s: New dcon is %08x\n", __func__, dcon);
|
||||
pr_debug("%s: dcon is %08x\n", __func__, dcon);
|
||||
|
||||
switch (chan->req_ch) {
|
||||
case DMACH_I2S_IN:
|
||||
@ -1235,7 +1231,7 @@ static void s3c2410_dma_resume_chan(struct s3c2410_dma_chan *cp)
|
||||
/* restore channel's hardware configuration */
|
||||
|
||||
if (!cp->in_use)
|
||||
return 0;
|
||||
return;
|
||||
|
||||
printk(KERN_INFO "dma%d: restoring configuration\n", cp->number);
|
||||
|
||||
@ -1246,8 +1242,6 @@ static void s3c2410_dma_resume_chan(struct s3c2410_dma_chan *cp)
|
||||
|
||||
if (cp->map != NULL)
|
||||
dma_sel.select(cp, cp->map);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void s3c2410_dma_resume(void)
|
||||
|
@ -152,7 +152,7 @@ static __init int s5p_gpioint_add(struct s3c_gpio_chip *chip)
|
||||
if (!gc)
|
||||
return -ENOMEM;
|
||||
ct = gc->chip_types;
|
||||
ct->chip.irq_ack = irq_gc_ack;
|
||||
ct->chip.irq_ack = irq_gc_ack_set_bit;
|
||||
ct->chip.irq_mask = irq_gc_mask_set_bit;
|
||||
ct->chip.irq_unmask = irq_gc_mask_clr_bit;
|
||||
ct->chip.irq_set_type = s5p_gpioint_set_type,
|
||||
|
@ -370,11 +370,11 @@ static void __init s5p_clocksource_init(void)
|
||||
|
||||
clock_rate = clk_get_rate(tin_source);
|
||||
|
||||
init_sched_clock(&cd, s5p_update_sched_clock, 32, clock_rate);
|
||||
|
||||
s5p_time_setup(timer_source.source_id, TCNT_MAX);
|
||||
s5p_time_start(timer_source.source_id, PERIODIC);
|
||||
|
||||
init_sched_clock(&cd, s5p_update_sched_clock, 32, clock_rate);
|
||||
|
||||
if (clocksource_register_hz(&time_clocksource, clock_rate))
|
||||
panic("%s: can't register clocksource\n", time_clocksource.name);
|
||||
}
|
||||
|
@ -12,6 +12,10 @@
|
||||
* it under the terms of the GNU General Public License version 2 as
|
||||
* published by the Free Software Foundation.
|
||||
*/
|
||||
|
||||
#ifndef __PLAT_DEVS_H
|
||||
#define __PLAT_DEVS_H __FILE__
|
||||
|
||||
#include <linux/platform_device.h>
|
||||
|
||||
struct s3c24xx_uart_resources {
|
||||
@ -159,3 +163,5 @@ extern struct platform_device s3c_device_ac97;
|
||||
*/
|
||||
extern void *s3c_set_platdata(void *pd, size_t pdsize,
|
||||
struct platform_device *pdev);
|
||||
|
||||
#endif /* __PLAT_DEVS_H */
|
||||
|
@ -39,6 +39,7 @@ struct s3c64xx_spi_csinfo {
|
||||
* @fifo_lvl_mask: All tx fifo_lvl fields start at offset-6
|
||||
* @rx_lvl_offset: Depends on tx fifo_lvl field and bus number
|
||||
* @high_speed: If the controller supports HIGH_SPEED_EN bit
|
||||
* @tx_st_done: Depends on tx fifo_lvl field
|
||||
*/
|
||||
struct s3c64xx_spi_info {
|
||||
int src_clk_nr;
|
||||
@ -53,6 +54,7 @@ struct s3c64xx_spi_info {
|
||||
int fifo_lvl_mask;
|
||||
int rx_lvl_offset;
|
||||
int high_speed;
|
||||
int tx_st_done;
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -55,7 +55,7 @@ static void __init s3c_init_uart_irq(struct s3c_uart_irq *uirq)
|
||||
gc = irq_alloc_generic_chip("s3c-uart", 1, uirq->base_irq, reg_base,
|
||||
handle_level_irq);
|
||||
ct = gc->chip_types;
|
||||
ct->chip.irq_ack = irq_gc_ack;
|
||||
ct->chip.irq_ack = irq_gc_ack_set_bit;
|
||||
ct->chip.irq_mask = irq_gc_mask_set_bit;
|
||||
ct->chip.irq_unmask = irq_gc_mask_clr_bit;
|
||||
ct->regs.ack = S3C64XX_UINTP;
|
||||
|
@ -12,6 +12,8 @@
|
||||
#include <linux/of.h>
|
||||
#include <linux/memblock.h>
|
||||
#include <linux/vmalloc.h>
|
||||
#include <linux/memory.h>
|
||||
|
||||
#include <asm/firmware.h>
|
||||
#include <asm/machdep.h>
|
||||
#include <asm/pSeries_reconfig.h>
|
||||
@ -20,24 +22,25 @@
|
||||
static unsigned long get_memblock_size(void)
|
||||
{
|
||||
struct device_node *np;
|
||||
unsigned int memblock_size = 0;
|
||||
unsigned int memblock_size = MIN_MEMORY_BLOCK_SIZE;
|
||||
struct resource r;
|
||||
|
||||
np = of_find_node_by_path("/ibm,dynamic-reconfiguration-memory");
|
||||
if (np) {
|
||||
const unsigned long *size;
|
||||
const __be64 *size;
|
||||
|
||||
size = of_get_property(np, "ibm,lmb-size", NULL);
|
||||
memblock_size = size ? *size : 0;
|
||||
|
||||
if (size)
|
||||
memblock_size = be64_to_cpup(size);
|
||||
of_node_put(np);
|
||||
} else {
|
||||
} else if (machine_is(pseries)) {
|
||||
/* This fallback really only applies to pseries */
|
||||
unsigned int memzero_size = 0;
|
||||
const unsigned int *regs;
|
||||
|
||||
np = of_find_node_by_path("/memory@0");
|
||||
if (np) {
|
||||
regs = of_get_property(np, "reg", NULL);
|
||||
memzero_size = regs ? regs[3] : 0;
|
||||
if (!of_address_to_resource(np, 0, &r))
|
||||
memzero_size = resource_size(&r);
|
||||
of_node_put(np);
|
||||
}
|
||||
|
||||
@ -50,16 +53,21 @@ static unsigned long get_memblock_size(void)
|
||||
sprintf(buf, "/memory@%x", memzero_size);
|
||||
np = of_find_node_by_path(buf);
|
||||
if (np) {
|
||||
regs = of_get_property(np, "reg", NULL);
|
||||
memblock_size = regs ? regs[3] : 0;
|
||||
if (!of_address_to_resource(np, 0, &r))
|
||||
memblock_size = resource_size(&r);
|
||||
of_node_put(np);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return memblock_size;
|
||||
}
|
||||
|
||||
/* WARNING: This is going to override the generic definition whenever
|
||||
* pseries is built-in regardless of what platform is active at boot
|
||||
* time. This is fine for now as this is the only "option" and it
|
||||
* should work everywhere. If not, we'll have to turn this into a
|
||||
* ppc_md. callback
|
||||
*/
|
||||
unsigned long memory_block_size_bytes(void)
|
||||
{
|
||||
return get_memblock_size();
|
||||
|
@ -57,6 +57,8 @@ static inline int pfn_valid(int pfn)
|
||||
return 0;
|
||||
}
|
||||
|
||||
#define early_pfn_valid(pfn) pfn_valid((pfn))
|
||||
|
||||
#endif /* CONFIG_DISCONTIGMEM */
|
||||
|
||||
#ifdef CONFIG_NEED_MULTIPLE_NODES
|
||||
|
@ -28,6 +28,8 @@ pmode_cr3: .long 0 /* Saved %cr3 */
|
||||
pmode_cr4: .long 0 /* Saved %cr4 */
|
||||
pmode_efer: .quad 0 /* Saved EFER */
|
||||
pmode_gdt: .quad 0
|
||||
pmode_misc_en: .quad 0 /* Saved MISC_ENABLE MSR */
|
||||
pmode_behavior: .long 0 /* Wakeup behavior flags */
|
||||
realmode_flags: .long 0
|
||||
real_magic: .long 0
|
||||
trampoline_segment: .word 0
|
||||
@ -91,6 +93,18 @@ wakeup_code:
|
||||
/* Call the C code */
|
||||
calll main
|
||||
|
||||
/* Restore MISC_ENABLE before entering protected mode, in case
|
||||
BIOS decided to clear XD_DISABLE during S3. */
|
||||
movl pmode_behavior, %eax
|
||||
btl $WAKEUP_BEHAVIOR_RESTORE_MISC_ENABLE, %eax
|
||||
jnc 1f
|
||||
|
||||
movl pmode_misc_en, %eax
|
||||
movl pmode_misc_en + 4, %edx
|
||||
movl $MSR_IA32_MISC_ENABLE, %ecx
|
||||
wrmsr
|
||||
1:
|
||||
|
||||
/* Do any other stuff... */
|
||||
|
||||
#ifndef CONFIG_64BIT
|
||||
|
@ -21,6 +21,9 @@ struct wakeup_header {
|
||||
u32 pmode_efer_low; /* Protected mode EFER */
|
||||
u32 pmode_efer_high;
|
||||
u64 pmode_gdt;
|
||||
u32 pmode_misc_en_low; /* Protected mode MISC_ENABLE */
|
||||
u32 pmode_misc_en_high;
|
||||
u32 pmode_behavior; /* Wakeup routine behavior flags */
|
||||
u32 realmode_flags;
|
||||
u32 real_magic;
|
||||
u16 trampoline_segment; /* segment with trampoline code, 64-bit only */
|
||||
@ -39,4 +42,7 @@ extern struct wakeup_header wakeup_header;
|
||||
#define WAKEUP_HEADER_SIGNATURE 0x51ee1111
|
||||
#define WAKEUP_END_SIGNATURE 0x65a22c82
|
||||
|
||||
/* Wakeup behavior bits */
|
||||
#define WAKEUP_BEHAVIOR_RESTORE_MISC_ENABLE 0
|
||||
|
||||
#endif /* ARCH_X86_KERNEL_ACPI_RM_WAKEUP_H */
|
||||
|
@ -77,6 +77,12 @@ int acpi_suspend_lowlevel(void)
|
||||
|
||||
header->pmode_cr0 = read_cr0();
|
||||
header->pmode_cr4 = read_cr4_safe();
|
||||
header->pmode_behavior = 0;
|
||||
if (!rdmsr_safe(MSR_IA32_MISC_ENABLE,
|
||||
&header->pmode_misc_en_low,
|
||||
&header->pmode_misc_en_high))
|
||||
header->pmode_behavior |=
|
||||
(1 << WAKEUP_BEHAVIOR_RESTORE_MISC_ENABLE);
|
||||
header->realmode_flags = acpi_realmode_flags;
|
||||
header->real_magic = 0x12345678;
|
||||
|
||||
|
@ -294,6 +294,14 @@ static struct dmi_system_id __initdata reboot_dmi_table[] = {
|
||||
DMI_MATCH(DMI_BOARD_NAME, "VersaLogic Menlow board"),
|
||||
},
|
||||
},
|
||||
{ /* Handle reboot issue on Acer Aspire one */
|
||||
.callback = set_bios_reboot,
|
||||
.ident = "Acer Aspire One A110",
|
||||
.matches = {
|
||||
DMI_MATCH(DMI_SYS_VENDOR, "Acer"),
|
||||
DMI_MATCH(DMI_PRODUCT_NAME, "AOA110"),
|
||||
},
|
||||
},
|
||||
{ }
|
||||
};
|
||||
|
||||
|
@ -28,6 +28,7 @@
|
||||
#include <linux/poison.h>
|
||||
#include <linux/dma-mapping.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/memory.h>
|
||||
#include <linux/memory_hotplug.h>
|
||||
#include <linux/nmi.h>
|
||||
#include <linux/gfp.h>
|
||||
@ -895,8 +896,6 @@ const char *arch_vma_name(struct vm_area_struct *vma)
|
||||
}
|
||||
|
||||
#ifdef CONFIG_X86_UV
|
||||
#define MIN_MEMORY_BLOCK_SIZE (1 << SECTION_SIZE_BITS)
|
||||
|
||||
unsigned long memory_block_size_bytes(void)
|
||||
{
|
||||
if (is_uv_system()) {
|
||||
|
@ -112,8 +112,10 @@ static void nmi_cpu_start(void *dummy)
|
||||
static int nmi_start(void)
|
||||
{
|
||||
get_online_cpus();
|
||||
on_each_cpu(nmi_cpu_start, NULL, 1);
|
||||
ctr_running = 1;
|
||||
/* make ctr_running visible to the nmi handler: */
|
||||
smp_mb();
|
||||
on_each_cpu(nmi_cpu_start, NULL, 1);
|
||||
put_online_cpus();
|
||||
return 0;
|
||||
}
|
||||
@ -504,15 +506,18 @@ static int nmi_setup(void)
|
||||
|
||||
nmi_enabled = 0;
|
||||
ctr_running = 0;
|
||||
barrier();
|
||||
/* make variables visible to the nmi handler: */
|
||||
smp_mb();
|
||||
err = register_die_notifier(&profile_exceptions_nb);
|
||||
if (err)
|
||||
goto fail;
|
||||
|
||||
get_online_cpus();
|
||||
register_cpu_notifier(&oprofile_cpu_nb);
|
||||
on_each_cpu(nmi_cpu_setup, NULL, 1);
|
||||
nmi_enabled = 1;
|
||||
/* make nmi_enabled visible to the nmi handler: */
|
||||
smp_mb();
|
||||
on_each_cpu(nmi_cpu_setup, NULL, 1);
|
||||
put_online_cpus();
|
||||
|
||||
return 0;
|
||||
@ -531,7 +536,8 @@ static void nmi_shutdown(void)
|
||||
nmi_enabled = 0;
|
||||
ctr_running = 0;
|
||||
put_online_cpus();
|
||||
barrier();
|
||||
/* make variables visible to the nmi handler: */
|
||||
smp_mb();
|
||||
unregister_die_notifier(&profile_exceptions_nb);
|
||||
msrs = &get_cpu_var(cpu_msrs);
|
||||
model->shutdown(msrs);
|
||||
|
@ -327,7 +327,7 @@ int __init pci_xen_hvm_init(void)
|
||||
}
|
||||
|
||||
#ifdef CONFIG_XEN_DOM0
|
||||
static int xen_register_pirq(u32 gsi, int triggering)
|
||||
static int xen_register_pirq(u32 gsi, int gsi_override, int triggering)
|
||||
{
|
||||
int rc, pirq, irq = -1;
|
||||
struct physdev_map_pirq map_irq;
|
||||
@ -344,16 +344,18 @@ static int xen_register_pirq(u32 gsi, int triggering)
|
||||
shareable = 1;
|
||||
name = "ioapic-level";
|
||||
}
|
||||
|
||||
pirq = xen_allocate_pirq_gsi(gsi);
|
||||
if (pirq < 0)
|
||||
goto out;
|
||||
|
||||
irq = xen_bind_pirq_gsi_to_irq(gsi, pirq, shareable, name);
|
||||
if (gsi_override >= 0)
|
||||
irq = xen_bind_pirq_gsi_to_irq(gsi_override, pirq, shareable, name);
|
||||
else
|
||||
irq = xen_bind_pirq_gsi_to_irq(gsi, pirq, shareable, name);
|
||||
if (irq < 0)
|
||||
goto out;
|
||||
|
||||
printk(KERN_DEBUG "xen: --> pirq=%d -> irq=%d\n", pirq, irq);
|
||||
printk(KERN_DEBUG "xen: --> pirq=%d -> irq=%d (gsi=%d)\n", pirq, irq, gsi);
|
||||
|
||||
map_irq.domid = DOMID_SELF;
|
||||
map_irq.type = MAP_PIRQ_TYPE_GSI;
|
||||
@ -370,7 +372,7 @@ out:
|
||||
return irq;
|
||||
}
|
||||
|
||||
static int xen_register_gsi(u32 gsi, int triggering, int polarity)
|
||||
static int xen_register_gsi(u32 gsi, int gsi_override, int triggering, int polarity)
|
||||
{
|
||||
int rc, irq;
|
||||
struct physdev_setup_gsi setup_gsi;
|
||||
@ -381,7 +383,7 @@ static int xen_register_gsi(u32 gsi, int triggering, int polarity)
|
||||
printk(KERN_DEBUG "xen: registering gsi %u triggering %d polarity %d\n",
|
||||
gsi, triggering, polarity);
|
||||
|
||||
irq = xen_register_pirq(gsi, triggering);
|
||||
irq = xen_register_pirq(gsi, gsi_override, triggering);
|
||||
|
||||
setup_gsi.gsi = gsi;
|
||||
setup_gsi.triggering = (triggering == ACPI_EDGE_SENSITIVE ? 0 : 1);
|
||||
@ -403,6 +405,8 @@ static __init void xen_setup_acpi_sci(void)
|
||||
int rc;
|
||||
int trigger, polarity;
|
||||
int gsi = acpi_sci_override_gsi;
|
||||
int irq = -1;
|
||||
int gsi_override = -1;
|
||||
|
||||
if (!gsi)
|
||||
return;
|
||||
@ -419,7 +423,25 @@ static __init void xen_setup_acpi_sci(void)
|
||||
printk(KERN_INFO "xen: sci override: global_irq=%d trigger=%d "
|
||||
"polarity=%d\n", gsi, trigger, polarity);
|
||||
|
||||
gsi = xen_register_gsi(gsi, trigger, polarity);
|
||||
/* Before we bind the GSI to a Linux IRQ, check whether
|
||||
* we need to override it with bus_irq (IRQ) value. Usually for
|
||||
* IRQs below IRQ_LEGACY_IRQ this holds IRQ == GSI, as so:
|
||||
* ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 9 low level)
|
||||
* but there are oddballs where the IRQ != GSI:
|
||||
* ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 20 low level)
|
||||
* which ends up being: gsi_to_irq[9] == 20
|
||||
* (which is what acpi_gsi_to_irq ends up calling when starting the
|
||||
* the ACPI interpreter and keels over since IRQ 9 has not been
|
||||
* setup as we had setup IRQ 20 for it).
|
||||
*/
|
||||
/* Check whether the GSI != IRQ */
|
||||
if (acpi_gsi_to_irq(gsi, &irq) == 0) {
|
||||
if (irq >= 0 && irq != gsi)
|
||||
/* Bugger, we MUST have that IRQ. */
|
||||
gsi_override = irq;
|
||||
}
|
||||
|
||||
gsi = xen_register_gsi(gsi, gsi_override, trigger, polarity);
|
||||
printk(KERN_INFO "xen: acpi sci %d\n", gsi);
|
||||
|
||||
return;
|
||||
@ -428,7 +450,7 @@ static __init void xen_setup_acpi_sci(void)
|
||||
static int acpi_register_gsi_xen(struct device *dev, u32 gsi,
|
||||
int trigger, int polarity)
|
||||
{
|
||||
return xen_register_gsi(gsi, trigger, polarity);
|
||||
return xen_register_gsi(gsi, -1 /* no GSI override */, trigger, polarity);
|
||||
}
|
||||
|
||||
static int __init pci_xen_initial_domain(void)
|
||||
@ -467,7 +489,7 @@ void __init xen_setup_pirqs(void)
|
||||
if (acpi_get_override_irq(irq, &trigger, &polarity) == -1)
|
||||
continue;
|
||||
|
||||
xen_register_pirq(irq,
|
||||
xen_register_pirq(irq, -1 /* no GSI override */,
|
||||
trigger ? ACPI_LEVEL_SENSITIVE : ACPI_EDGE_SENSITIVE);
|
||||
}
|
||||
}
|
||||
|
@ -504,9 +504,6 @@ void __init efi_init(void)
|
||||
x86_platform.set_wallclock = efi_set_rtc_mmss;
|
||||
#endif
|
||||
|
||||
/* Setup for EFI runtime service */
|
||||
reboot_type = BOOT_EFI;
|
||||
|
||||
#if EFI_DEBUG
|
||||
print_efi_memmap();
|
||||
#endif
|
||||
|
@ -1232,7 +1232,11 @@ static void xen_flush_tlb_others(const struct cpumask *cpus,
|
||||
{
|
||||
struct {
|
||||
struct mmuext_op op;
|
||||
#ifdef CONFIG_SMP
|
||||
DECLARE_BITMAP(mask, num_processors);
|
||||
#else
|
||||
DECLARE_BITMAP(mask, NR_CPUS);
|
||||
#endif
|
||||
} *args;
|
||||
struct multicall_space mcs;
|
||||
|
||||
|
@ -2773,11 +2773,14 @@ static void __cfq_exit_single_io_context(struct cfq_data *cfqd,
|
||||
smp_wmb();
|
||||
cic->key = cfqd_dead_key(cfqd);
|
||||
|
||||
rcu_read_lock();
|
||||
if (rcu_dereference(ioc->ioc_data) == cic) {
|
||||
rcu_read_unlock();
|
||||
spin_lock(&ioc->lock);
|
||||
rcu_assign_pointer(ioc->ioc_data, NULL);
|
||||
spin_unlock(&ioc->lock);
|
||||
}
|
||||
} else
|
||||
rcu_read_unlock();
|
||||
|
||||
if (cic->cfqq[BLK_RW_ASYNC]) {
|
||||
cfq_exit_cfqq(cfqd, cic->cfqq[BLK_RW_ASYNC]);
|
||||
@ -3084,7 +3087,8 @@ cfq_drop_dead_cic(struct cfq_data *cfqd, struct io_context *ioc,
|
||||
|
||||
spin_lock_irqsave(&ioc->lock, flags);
|
||||
|
||||
BUG_ON(ioc->ioc_data == cic);
|
||||
BUG_ON(rcu_dereference_check(ioc->ioc_data,
|
||||
lockdep_is_held(&ioc->lock)) == cic);
|
||||
|
||||
radix_tree_delete(&ioc->radix_root, cfqd->cic_index);
|
||||
hlist_del_rcu(&cic->cic_list);
|
||||
|
@ -30,7 +30,6 @@
|
||||
static DEFINE_MUTEX(mem_sysfs_mutex);
|
||||
|
||||
#define MEMORY_CLASS_NAME "memory"
|
||||
#define MIN_MEMORY_BLOCK_SIZE (1 << SECTION_SIZE_BITS)
|
||||
|
||||
static int sections_per_block;
|
||||
|
||||
|
@ -9,6 +9,7 @@
|
||||
#include <linux/syscore_ops.h>
|
||||
#include <linux/mutex.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/interrupt.h>
|
||||
|
||||
static LIST_HEAD(syscore_ops_list);
|
||||
static DEFINE_MUTEX(syscore_ops_lock);
|
||||
@ -48,6 +49,13 @@ int syscore_suspend(void)
|
||||
struct syscore_ops *ops;
|
||||
int ret = 0;
|
||||
|
||||
pr_debug("Checking wakeup interrupts\n");
|
||||
|
||||
/* Return error code if there are any wakeup interrupts pending. */
|
||||
ret = check_wakeup_irqs();
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
WARN_ONCE(!irqs_disabled(),
|
||||
"Interrupts enabled before system core suspend.\n");
|
||||
|
||||
|
@ -79,7 +79,7 @@ static int _drbd_md_sync_page_io(struct drbd_conf *mdev,
|
||||
md_io.error = 0;
|
||||
|
||||
if ((rw & WRITE) && !test_bit(MD_NO_FUA, &mdev->flags))
|
||||
rw |= REQ_FUA;
|
||||
rw |= REQ_FUA | REQ_FLUSH;
|
||||
rw |= REQ_SYNC;
|
||||
|
||||
bio = bio_alloc(GFP_NOIO, 1);
|
||||
|
@ -112,9 +112,6 @@ struct drbd_bitmap {
|
||||
struct task_struct *bm_task;
|
||||
};
|
||||
|
||||
static int __bm_change_bits_to(struct drbd_conf *mdev, const unsigned long s,
|
||||
unsigned long e, int val, const enum km_type km);
|
||||
|
||||
#define bm_print_lock_info(m) __bm_print_lock_info(m, __func__)
|
||||
static void __bm_print_lock_info(struct drbd_conf *mdev, const char *func)
|
||||
{
|
||||
@ -994,6 +991,9 @@ static void bm_page_io_async(struct bm_aio_ctx *ctx, int page_nr, int rw) __must
|
||||
bio_endio(bio, -EIO);
|
||||
} else {
|
||||
submit_bio(rw, bio);
|
||||
/* this should not count as user activity and cause the
|
||||
* resync to throttle -- see drbd_rs_should_slow_down(). */
|
||||
atomic_add(len >> 9, &mdev->rs_sect_ev);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1256,7 +1256,7 @@ unsigned long _drbd_bm_find_next_zero(struct drbd_conf *mdev, unsigned long bm_f
|
||||
* expected to be called for only a few bits (e - s about BITS_PER_LONG).
|
||||
* Must hold bitmap lock already. */
|
||||
static int __bm_change_bits_to(struct drbd_conf *mdev, const unsigned long s,
|
||||
unsigned long e, int val, const enum km_type km)
|
||||
unsigned long e, int val)
|
||||
{
|
||||
struct drbd_bitmap *b = mdev->bitmap;
|
||||
unsigned long *p_addr = NULL;
|
||||
@ -1274,14 +1274,14 @@ static int __bm_change_bits_to(struct drbd_conf *mdev, const unsigned long s,
|
||||
unsigned int page_nr = bm_bit_to_page_idx(b, bitnr);
|
||||
if (page_nr != last_page_nr) {
|
||||
if (p_addr)
|
||||
__bm_unmap(p_addr, km);
|
||||
__bm_unmap(p_addr, KM_IRQ1);
|
||||
if (c < 0)
|
||||
bm_set_page_lazy_writeout(b->bm_pages[last_page_nr]);
|
||||
else if (c > 0)
|
||||
bm_set_page_need_writeout(b->bm_pages[last_page_nr]);
|
||||
changed_total += c;
|
||||
c = 0;
|
||||
p_addr = __bm_map_pidx(b, page_nr, km);
|
||||
p_addr = __bm_map_pidx(b, page_nr, KM_IRQ1);
|
||||
last_page_nr = page_nr;
|
||||
}
|
||||
if (val)
|
||||
@ -1290,7 +1290,7 @@ static int __bm_change_bits_to(struct drbd_conf *mdev, const unsigned long s,
|
||||
c -= (0 != __test_and_clear_bit_le(bitnr & BITS_PER_PAGE_MASK, p_addr));
|
||||
}
|
||||
if (p_addr)
|
||||
__bm_unmap(p_addr, km);
|
||||
__bm_unmap(p_addr, KM_IRQ1);
|
||||
if (c < 0)
|
||||
bm_set_page_lazy_writeout(b->bm_pages[last_page_nr]);
|
||||
else if (c > 0)
|
||||
@ -1318,7 +1318,7 @@ static int bm_change_bits_to(struct drbd_conf *mdev, const unsigned long s,
|
||||
if ((val ? BM_DONT_SET : BM_DONT_CLEAR) & b->bm_flags)
|
||||
bm_print_lock_info(mdev);
|
||||
|
||||
c = __bm_change_bits_to(mdev, s, e, val, KM_IRQ1);
|
||||
c = __bm_change_bits_to(mdev, s, e, val);
|
||||
|
||||
spin_unlock_irqrestore(&b->bm_lock, flags);
|
||||
return c;
|
||||
@ -1343,16 +1343,17 @@ static inline void bm_set_full_words_within_one_page(struct drbd_bitmap *b,
|
||||
{
|
||||
int i;
|
||||
int bits;
|
||||
unsigned long *paddr = kmap_atomic(b->bm_pages[page_nr], KM_USER0);
|
||||
unsigned long *paddr = kmap_atomic(b->bm_pages[page_nr], KM_IRQ1);
|
||||
for (i = first_word; i < last_word; i++) {
|
||||
bits = hweight_long(paddr[i]);
|
||||
paddr[i] = ~0UL;
|
||||
b->bm_set += BITS_PER_LONG - bits;
|
||||
}
|
||||
kunmap_atomic(paddr, KM_USER0);
|
||||
kunmap_atomic(paddr, KM_IRQ1);
|
||||
}
|
||||
|
||||
/* Same thing as drbd_bm_set_bits, but without taking the spin_lock_irqsave.
|
||||
/* Same thing as drbd_bm_set_bits,
|
||||
* but more efficient for a large bit range.
|
||||
* You must first drbd_bm_lock().
|
||||
* Can be called to set the whole bitmap in one go.
|
||||
* Sets bits from s to e _inclusive_. */
|
||||
@ -1366,6 +1367,7 @@ void _drbd_bm_set_bits(struct drbd_conf *mdev, const unsigned long s, const unsi
|
||||
* Do not use memset, because we must account for changes,
|
||||
* so we need to loop over the words with hweight() anyways.
|
||||
*/
|
||||
struct drbd_bitmap *b = mdev->bitmap;
|
||||
unsigned long sl = ALIGN(s,BITS_PER_LONG);
|
||||
unsigned long el = (e+1) & ~((unsigned long)BITS_PER_LONG-1);
|
||||
int first_page;
|
||||
@ -1376,15 +1378,19 @@ void _drbd_bm_set_bits(struct drbd_conf *mdev, const unsigned long s, const unsi
|
||||
|
||||
if (e - s <= 3*BITS_PER_LONG) {
|
||||
/* don't bother; el and sl may even be wrong. */
|
||||
__bm_change_bits_to(mdev, s, e, 1, KM_USER0);
|
||||
spin_lock_irq(&b->bm_lock);
|
||||
__bm_change_bits_to(mdev, s, e, 1);
|
||||
spin_unlock_irq(&b->bm_lock);
|
||||
return;
|
||||
}
|
||||
|
||||
/* difference is large enough that we can trust sl and el */
|
||||
|
||||
spin_lock_irq(&b->bm_lock);
|
||||
|
||||
/* bits filling the current long */
|
||||
if (sl)
|
||||
__bm_change_bits_to(mdev, s, sl-1, 1, KM_USER0);
|
||||
__bm_change_bits_to(mdev, s, sl-1, 1);
|
||||
|
||||
first_page = sl >> (3 + PAGE_SHIFT);
|
||||
last_page = el >> (3 + PAGE_SHIFT);
|
||||
@ -1397,8 +1403,10 @@ void _drbd_bm_set_bits(struct drbd_conf *mdev, const unsigned long s, const unsi
|
||||
/* first and full pages, unless first page == last page */
|
||||
for (page_nr = first_page; page_nr < last_page; page_nr++) {
|
||||
bm_set_full_words_within_one_page(mdev->bitmap, page_nr, first_word, last_word);
|
||||
spin_unlock_irq(&b->bm_lock);
|
||||
cond_resched();
|
||||
first_word = 0;
|
||||
spin_lock_irq(&b->bm_lock);
|
||||
}
|
||||
|
||||
/* last page (respectively only page, for first page == last page) */
|
||||
@ -1411,7 +1419,8 @@ void _drbd_bm_set_bits(struct drbd_conf *mdev, const unsigned long s, const unsi
|
||||
* it would trigger an assert in __bm_change_bits_to()
|
||||
*/
|
||||
if (el <= e)
|
||||
__bm_change_bits_to(mdev, el, e, 1, KM_USER0);
|
||||
__bm_change_bits_to(mdev, el, e, 1);
|
||||
spin_unlock_irq(&b->bm_lock);
|
||||
}
|
||||
|
||||
/* returns bit state
|
||||
|
@ -4602,6 +4602,11 @@ int drbd_asender(struct drbd_thread *thi)
|
||||
dev_err(DEV, "meta connection shut down by peer.\n");
|
||||
goto reconnect;
|
||||
} else if (rv == -EAGAIN) {
|
||||
/* If the data socket received something meanwhile,
|
||||
* that is good enough: peer is still alive. */
|
||||
if (time_after(mdev->last_received,
|
||||
jiffies - mdev->meta.socket->sk->sk_rcvtimeo))
|
||||
continue;
|
||||
if (ping_timeout_active) {
|
||||
dev_err(DEV, "PingAck did not arrive in time.\n");
|
||||
goto reconnect;
|
||||
@ -4637,6 +4642,7 @@ int drbd_asender(struct drbd_thread *thi)
|
||||
goto reconnect;
|
||||
}
|
||||
if (received == expect) {
|
||||
mdev->last_received = jiffies;
|
||||
D_ASSERT(cmd != NULL);
|
||||
if (!cmd->process(mdev, h))
|
||||
goto reconnect;
|
||||
|
@ -536,12 +536,7 @@ static int w_make_resync_request(struct drbd_conf *mdev,
|
||||
return 1;
|
||||
}
|
||||
|
||||
/* starting with drbd 8.3.8, we can handle multi-bio EEs,
|
||||
* if it should be necessary */
|
||||
max_bio_size =
|
||||
mdev->agreed_pro_version < 94 ? queue_max_hw_sectors(mdev->rq_queue) << 9 :
|
||||
mdev->agreed_pro_version < 95 ? DRBD_MAX_SIZE_H80_PACKET : DRBD_MAX_BIO_SIZE;
|
||||
|
||||
max_bio_size = queue_max_hw_sectors(mdev->rq_queue) << 9;
|
||||
number = drbd_rs_number_requests(mdev);
|
||||
if (number == 0)
|
||||
goto requeue;
|
||||
|
@ -90,9 +90,10 @@
|
||||
#define G4x_GMCH_SIZE_MASK (0xf << 8)
|
||||
#define G4x_GMCH_SIZE_1M (0x1 << 8)
|
||||
#define G4x_GMCH_SIZE_2M (0x3 << 8)
|
||||
#define G4x_GMCH_SIZE_VT_1M (0x9 << 8)
|
||||
#define G4x_GMCH_SIZE_VT_1_5M (0xa << 8)
|
||||
#define G4x_GMCH_SIZE_VT_2M (0xc << 8)
|
||||
#define G4x_GMCH_SIZE_VT_EN (0x8 << 8)
|
||||
#define G4x_GMCH_SIZE_VT_1M (G4x_GMCH_SIZE_1M | G4x_GMCH_SIZE_VT_EN)
|
||||
#define G4x_GMCH_SIZE_VT_1_5M ((0x2 << 8) | G4x_GMCH_SIZE_VT_EN)
|
||||
#define G4x_GMCH_SIZE_VT_2M (G4x_GMCH_SIZE_2M | G4x_GMCH_SIZE_VT_EN)
|
||||
|
||||
#define GFX_FLSH_CNTL 0x2170 /* 915+ */
|
||||
|
||||
|
@ -759,7 +759,7 @@ static void __exit acpi_cpufreq_exit(void)
|
||||
|
||||
cpufreq_unregister_driver(&acpi_cpufreq_driver);
|
||||
|
||||
free_percpu(acpi_perf_data);
|
||||
free_acpi_perf_data();
|
||||
}
|
||||
|
||||
module_param(acpi_pstate_strict, uint, 0644);
|
||||
|
@ -264,6 +264,7 @@ static char ohci_driver_name[] = KBUILD_MODNAME;
|
||||
#define PCI_DEVICE_ID_AGERE_FW643 0x5901
|
||||
#define PCI_DEVICE_ID_JMICRON_JMB38X_FW 0x2380
|
||||
#define PCI_DEVICE_ID_TI_TSB12LV22 0x8009
|
||||
#define PCI_VENDOR_ID_PINNACLE_SYSTEMS 0x11bd
|
||||
|
||||
#define QUIRK_CYCLE_TIMER 1
|
||||
#define QUIRK_RESET_PACKET 2
|
||||
@ -3190,6 +3191,11 @@ static int __devinit pci_probe(struct pci_dev *dev,
|
||||
int i, err;
|
||||
size_t size;
|
||||
|
||||
if (dev->vendor == PCI_VENDOR_ID_PINNACLE_SYSTEMS) {
|
||||
dev_err(&dev->dev, "Pinnacle MovieBoard is not yet supported\n");
|
||||
return -ENOSYS;
|
||||
}
|
||||
|
||||
ohci = kzalloc(sizeof(*ohci), GFP_KERNEL);
|
||||
if (ohci == NULL) {
|
||||
err = -ENOMEM;
|
||||
|
@ -223,7 +223,7 @@ static void lnw_irq_handler(unsigned irq, struct irq_desc *desc)
|
||||
gedr = gpio_reg(&lnw->chip, base, GEDR);
|
||||
pending = readl(gedr);
|
||||
while (pending) {
|
||||
gpio = __ffs(pending) - 1;
|
||||
gpio = __ffs(pending);
|
||||
mask = BIT(gpio);
|
||||
pending &= ~mask;
|
||||
/* Clear before handling so we can't lose an edge */
|
||||
|
@ -81,8 +81,10 @@ void tps65910_gpio_init(struct tps65910 *tps65910, int gpio_base)
|
||||
switch(tps65910_chip_id(tps65910)) {
|
||||
case TPS65910:
|
||||
tps65910->gpio.ngpio = 6;
|
||||
break;
|
||||
case TPS65911:
|
||||
tps65910->gpio.ngpio = 9;
|
||||
break;
|
||||
default:
|
||||
return;
|
||||
}
|
||||
|
@ -886,9 +886,6 @@ int drm_mode_group_init(struct drm_device *dev, struct drm_mode_group *group)
|
||||
total_objects += dev->mode_config.num_connector;
|
||||
total_objects += dev->mode_config.num_encoder;
|
||||
|
||||
if (total_objects == 0)
|
||||
return -EINVAL;
|
||||
|
||||
group->id_list = kzalloc(total_objects * sizeof(uint32_t), GFP_KERNEL);
|
||||
if (!group->id_list)
|
||||
return -ENOMEM;
|
||||
|
@ -1207,13 +1207,17 @@ static int i915_context_status(struct seq_file *m, void *unused)
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
seq_printf(m, "power context ");
|
||||
describe_obj(m, dev_priv->pwrctx);
|
||||
seq_printf(m, "\n");
|
||||
if (dev_priv->pwrctx) {
|
||||
seq_printf(m, "power context ");
|
||||
describe_obj(m, dev_priv->pwrctx);
|
||||
seq_printf(m, "\n");
|
||||
}
|
||||
|
||||
seq_printf(m, "render context ");
|
||||
describe_obj(m, dev_priv->renderctx);
|
||||
seq_printf(m, "\n");
|
||||
if (dev_priv->renderctx) {
|
||||
seq_printf(m, "render context ");
|
||||
describe_obj(m, dev_priv->renderctx);
|
||||
seq_printf(m, "\n");
|
||||
}
|
||||
|
||||
mutex_unlock(&dev->mode_config.mutex);
|
||||
|
||||
|
@ -1266,30 +1266,6 @@ static int i915_load_modeset_init(struct drm_device *dev)
|
||||
|
||||
intel_modeset_gem_init(dev);
|
||||
|
||||
if (IS_IVYBRIDGE(dev)) {
|
||||
/* Share pre & uninstall handlers with ILK/SNB */
|
||||
dev->driver->irq_handler = ivybridge_irq_handler;
|
||||
dev->driver->irq_preinstall = ironlake_irq_preinstall;
|
||||
dev->driver->irq_postinstall = ivybridge_irq_postinstall;
|
||||
dev->driver->irq_uninstall = ironlake_irq_uninstall;
|
||||
dev->driver->enable_vblank = ivybridge_enable_vblank;
|
||||
dev->driver->disable_vblank = ivybridge_disable_vblank;
|
||||
} else if (HAS_PCH_SPLIT(dev)) {
|
||||
dev->driver->irq_handler = ironlake_irq_handler;
|
||||
dev->driver->irq_preinstall = ironlake_irq_preinstall;
|
||||
dev->driver->irq_postinstall = ironlake_irq_postinstall;
|
||||
dev->driver->irq_uninstall = ironlake_irq_uninstall;
|
||||
dev->driver->enable_vblank = ironlake_enable_vblank;
|
||||
dev->driver->disable_vblank = ironlake_disable_vblank;
|
||||
} else {
|
||||
dev->driver->irq_preinstall = i915_driver_irq_preinstall;
|
||||
dev->driver->irq_postinstall = i915_driver_irq_postinstall;
|
||||
dev->driver->irq_uninstall = i915_driver_irq_uninstall;
|
||||
dev->driver->irq_handler = i915_driver_irq_handler;
|
||||
dev->driver->enable_vblank = i915_enable_vblank;
|
||||
dev->driver->disable_vblank = i915_disable_vblank;
|
||||
}
|
||||
|
||||
ret = drm_irq_install(dev);
|
||||
if (ret)
|
||||
goto cleanup_gem;
|
||||
@ -1967,7 +1943,7 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags)
|
||||
if (!dev_priv->mm.gtt) {
|
||||
DRM_ERROR("Failed to initialize GTT\n");
|
||||
ret = -ENODEV;
|
||||
goto out_iomapfree;
|
||||
goto out_rmmap;
|
||||
}
|
||||
|
||||
agp_size = dev_priv->mm.gtt->gtt_mappable_entries << PAGE_SHIFT;
|
||||
@ -2011,18 +1987,13 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags)
|
||||
if (dev_priv->wq == NULL) {
|
||||
DRM_ERROR("Failed to create our workqueue.\n");
|
||||
ret = -ENOMEM;
|
||||
goto out_iomapfree;
|
||||
goto out_mtrrfree;
|
||||
}
|
||||
|
||||
/* enable GEM by default */
|
||||
dev_priv->has_gem = 1;
|
||||
|
||||
dev->driver->get_vblank_counter = i915_get_vblank_counter;
|
||||
dev->max_vblank_count = 0xffffff; /* only 24 bits of frame count */
|
||||
if (IS_G4X(dev) || IS_GEN5(dev) || IS_GEN6(dev) || IS_IVYBRIDGE(dev)) {
|
||||
dev->max_vblank_count = 0xffffffff; /* full 32 bit counter */
|
||||
dev->driver->get_vblank_counter = gm45_get_vblank_counter;
|
||||
}
|
||||
intel_irq_init(dev);
|
||||
|
||||
/* Try to make sure MCHBAR is enabled before poking at it */
|
||||
intel_setup_mchbar(dev);
|
||||
@ -2103,13 +2074,21 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags)
|
||||
return 0;
|
||||
|
||||
out_gem_unload:
|
||||
if (dev_priv->mm.inactive_shrinker.shrink)
|
||||
unregister_shrinker(&dev_priv->mm.inactive_shrinker);
|
||||
|
||||
if (dev->pdev->msi_enabled)
|
||||
pci_disable_msi(dev->pdev);
|
||||
|
||||
intel_teardown_gmbus(dev);
|
||||
intel_teardown_mchbar(dev);
|
||||
destroy_workqueue(dev_priv->wq);
|
||||
out_iomapfree:
|
||||
out_mtrrfree:
|
||||
if (dev_priv->mm.gtt_mtrr >= 0) {
|
||||
mtrr_del(dev_priv->mm.gtt_mtrr, dev->agp->base,
|
||||
dev->agp->agp_info.aper_size * 1024 * 1024);
|
||||
dev_priv->mm.gtt_mtrr = -1;
|
||||
}
|
||||
io_mapping_free(dev_priv->mm.gtt_mapping);
|
||||
out_rmmap:
|
||||
pci_iounmap(dev->pdev, dev_priv->regs);
|
||||
|
@ -52,7 +52,7 @@ module_param_named(powersave, i915_powersave, int, 0600);
|
||||
unsigned int i915_semaphores = 0;
|
||||
module_param_named(semaphores, i915_semaphores, int, 0600);
|
||||
|
||||
unsigned int i915_enable_rc6 = 1;
|
||||
unsigned int i915_enable_rc6 = 0;
|
||||
module_param_named(i915_enable_rc6, i915_enable_rc6, int, 0600);
|
||||
|
||||
unsigned int i915_enable_fbc = 0;
|
||||
@ -577,6 +577,7 @@ int i915_reset(struct drm_device *dev, u8 flags)
|
||||
if (get_seconds() - dev_priv->last_gpu_reset < 5) {
|
||||
DRM_ERROR("GPU hanging too fast, declaring wedged!\n");
|
||||
} else switch (INTEL_INFO(dev)->gen) {
|
||||
case 7:
|
||||
case 6:
|
||||
ret = gen6_do_reset(dev, flags);
|
||||
/* If reset with a user forcewake, try to restore */
|
||||
@ -765,14 +766,6 @@ static struct drm_driver driver = {
|
||||
.resume = i915_resume,
|
||||
|
||||
.device_is_agp = i915_driver_device_is_agp,
|
||||
.enable_vblank = i915_enable_vblank,
|
||||
.disable_vblank = i915_disable_vblank,
|
||||
.get_vblank_timestamp = i915_get_vblank_timestamp,
|
||||
.get_scanout_position = i915_get_crtc_scanoutpos,
|
||||
.irq_preinstall = i915_driver_irq_preinstall,
|
||||
.irq_postinstall = i915_driver_irq_postinstall,
|
||||
.irq_uninstall = i915_driver_irq_uninstall,
|
||||
.irq_handler = i915_driver_irq_handler,
|
||||
.reclaim_buffers = drm_core_reclaim_buffers,
|
||||
.master_create = i915_master_create,
|
||||
.master_destroy = i915_master_destroy,
|
||||
|
@ -997,8 +997,6 @@ extern unsigned int i915_enable_fbc;
|
||||
|
||||
extern int i915_suspend(struct drm_device *dev, pm_message_t state);
|
||||
extern int i915_resume(struct drm_device *dev);
|
||||
extern void i915_save_display(struct drm_device *dev);
|
||||
extern void i915_restore_display(struct drm_device *dev);
|
||||
extern int i915_master_create(struct drm_device *dev, struct drm_master *master);
|
||||
extern void i915_master_destroy(struct drm_device *dev, struct drm_master *master);
|
||||
|
||||
@ -1033,33 +1031,12 @@ extern int i915_irq_emit(struct drm_device *dev, void *data,
|
||||
extern int i915_irq_wait(struct drm_device *dev, void *data,
|
||||
struct drm_file *file_priv);
|
||||
|
||||
extern irqreturn_t i915_driver_irq_handler(DRM_IRQ_ARGS);
|
||||
extern void i915_driver_irq_preinstall(struct drm_device * dev);
|
||||
extern int i915_driver_irq_postinstall(struct drm_device *dev);
|
||||
extern void i915_driver_irq_uninstall(struct drm_device * dev);
|
||||
|
||||
extern irqreturn_t ironlake_irq_handler(DRM_IRQ_ARGS);
|
||||
extern void ironlake_irq_preinstall(struct drm_device *dev);
|
||||
extern int ironlake_irq_postinstall(struct drm_device *dev);
|
||||
extern void ironlake_irq_uninstall(struct drm_device *dev);
|
||||
|
||||
extern irqreturn_t ivybridge_irq_handler(DRM_IRQ_ARGS);
|
||||
extern void ivybridge_irq_preinstall(struct drm_device *dev);
|
||||
extern int ivybridge_irq_postinstall(struct drm_device *dev);
|
||||
extern void ivybridge_irq_uninstall(struct drm_device *dev);
|
||||
extern void intel_irq_init(struct drm_device *dev);
|
||||
|
||||
extern int i915_vblank_pipe_set(struct drm_device *dev, void *data,
|
||||
struct drm_file *file_priv);
|
||||
extern int i915_vblank_pipe_get(struct drm_device *dev, void *data,
|
||||
struct drm_file *file_priv);
|
||||
extern int i915_enable_vblank(struct drm_device *dev, int crtc);
|
||||
extern void i915_disable_vblank(struct drm_device *dev, int crtc);
|
||||
extern int ironlake_enable_vblank(struct drm_device *dev, int crtc);
|
||||
extern void ironlake_disable_vblank(struct drm_device *dev, int crtc);
|
||||
extern int ivybridge_enable_vblank(struct drm_device *dev, int crtc);
|
||||
extern void ivybridge_disable_vblank(struct drm_device *dev, int crtc);
|
||||
extern u32 i915_get_vblank_counter(struct drm_device *dev, int crtc);
|
||||
extern u32 gm45_get_vblank_counter(struct drm_device *dev, int crtc);
|
||||
extern int i915_vblank_swap(struct drm_device *dev, void *data,
|
||||
struct drm_file *file_priv);
|
||||
|
||||
@ -1070,13 +1047,6 @@ void
|
||||
i915_disable_pipestat(drm_i915_private_t *dev_priv, int pipe, u32 mask);
|
||||
|
||||
void intel_enable_asle (struct drm_device *dev);
|
||||
int i915_get_vblank_timestamp(struct drm_device *dev, int crtc,
|
||||
int *max_error,
|
||||
struct timeval *vblank_time,
|
||||
unsigned flags);
|
||||
|
||||
int i915_get_crtc_scanoutpos(struct drm_device *dev, int pipe,
|
||||
int *vpos, int *hpos);
|
||||
|
||||
#ifdef CONFIG_DEBUG_FS
|
||||
extern void i915_destroy_error_state(struct drm_device *dev);
|
||||
|
@ -152,7 +152,7 @@ i915_pipe_enabled(struct drm_device *dev, int pipe)
|
||||
/* Called from drm generic code, passed a 'crtc', which
|
||||
* we use as a pipe index
|
||||
*/
|
||||
u32 i915_get_vblank_counter(struct drm_device *dev, int pipe)
|
||||
static u32 i915_get_vblank_counter(struct drm_device *dev, int pipe)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
unsigned long high_frame;
|
||||
@ -184,7 +184,7 @@ u32 i915_get_vblank_counter(struct drm_device *dev, int pipe)
|
||||
return (high1 << 8) | low;
|
||||
}
|
||||
|
||||
u32 gm45_get_vblank_counter(struct drm_device *dev, int pipe)
|
||||
static u32 gm45_get_vblank_counter(struct drm_device *dev, int pipe)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
int reg = PIPE_FRMCOUNT_GM45(pipe);
|
||||
@ -198,7 +198,7 @@ u32 gm45_get_vblank_counter(struct drm_device *dev, int pipe)
|
||||
return I915_READ(reg);
|
||||
}
|
||||
|
||||
int i915_get_crtc_scanoutpos(struct drm_device *dev, int pipe,
|
||||
static int i915_get_crtc_scanoutpos(struct drm_device *dev, int pipe,
|
||||
int *vpos, int *hpos)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
@ -264,7 +264,7 @@ int i915_get_crtc_scanoutpos(struct drm_device *dev, int pipe,
|
||||
return ret;
|
||||
}
|
||||
|
||||
int i915_get_vblank_timestamp(struct drm_device *dev, int pipe,
|
||||
static int i915_get_vblank_timestamp(struct drm_device *dev, int pipe,
|
||||
int *max_error,
|
||||
struct timeval *vblank_time,
|
||||
unsigned flags)
|
||||
@ -462,7 +462,7 @@ static void pch_irq_handler(struct drm_device *dev)
|
||||
DRM_DEBUG_DRIVER("PCH transcoder A underrun interrupt\n");
|
||||
}
|
||||
|
||||
irqreturn_t ivybridge_irq_handler(DRM_IRQ_ARGS)
|
||||
static irqreturn_t ivybridge_irq_handler(DRM_IRQ_ARGS)
|
||||
{
|
||||
struct drm_device *dev = (struct drm_device *) arg;
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
@ -550,7 +550,7 @@ done:
|
||||
return ret;
|
||||
}
|
||||
|
||||
irqreturn_t ironlake_irq_handler(DRM_IRQ_ARGS)
|
||||
static irqreturn_t ironlake_irq_handler(DRM_IRQ_ARGS)
|
||||
{
|
||||
struct drm_device *dev = (struct drm_device *) arg;
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
@ -1209,7 +1209,7 @@ static void i915_pageflip_stall_check(struct drm_device *dev, int pipe)
|
||||
}
|
||||
}
|
||||
|
||||
irqreturn_t i915_driver_irq_handler(DRM_IRQ_ARGS)
|
||||
static irqreturn_t i915_driver_irq_handler(DRM_IRQ_ARGS)
|
||||
{
|
||||
struct drm_device *dev = (struct drm_device *) arg;
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
@ -1454,7 +1454,7 @@ int i915_irq_wait(struct drm_device *dev, void *data,
|
||||
/* Called from drm generic code, passed 'crtc' which
|
||||
* we use as a pipe index
|
||||
*/
|
||||
int i915_enable_vblank(struct drm_device *dev, int pipe)
|
||||
static int i915_enable_vblank(struct drm_device *dev, int pipe)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
unsigned long irqflags;
|
||||
@ -1478,7 +1478,7 @@ int i915_enable_vblank(struct drm_device *dev, int pipe)
|
||||
return 0;
|
||||
}
|
||||
|
||||
int ironlake_enable_vblank(struct drm_device *dev, int pipe)
|
||||
static int ironlake_enable_vblank(struct drm_device *dev, int pipe)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
unsigned long irqflags;
|
||||
@ -1494,7 +1494,7 @@ int ironlake_enable_vblank(struct drm_device *dev, int pipe)
|
||||
return 0;
|
||||
}
|
||||
|
||||
int ivybridge_enable_vblank(struct drm_device *dev, int pipe)
|
||||
static int ivybridge_enable_vblank(struct drm_device *dev, int pipe)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
unsigned long irqflags;
|
||||
@ -1513,7 +1513,7 @@ int ivybridge_enable_vblank(struct drm_device *dev, int pipe)
|
||||
/* Called from drm generic code, passed 'crtc' which
|
||||
* we use as a pipe index
|
||||
*/
|
||||
void i915_disable_vblank(struct drm_device *dev, int pipe)
|
||||
static void i915_disable_vblank(struct drm_device *dev, int pipe)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
unsigned long irqflags;
|
||||
@ -1529,7 +1529,7 @@ void i915_disable_vblank(struct drm_device *dev, int pipe)
|
||||
spin_unlock_irqrestore(&dev_priv->irq_lock, irqflags);
|
||||
}
|
||||
|
||||
void ironlake_disable_vblank(struct drm_device *dev, int pipe)
|
||||
static void ironlake_disable_vblank(struct drm_device *dev, int pipe)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
unsigned long irqflags;
|
||||
@ -1540,7 +1540,7 @@ void ironlake_disable_vblank(struct drm_device *dev, int pipe)
|
||||
spin_unlock_irqrestore(&dev_priv->irq_lock, irqflags);
|
||||
}
|
||||
|
||||
void ivybridge_disable_vblank(struct drm_device *dev, int pipe)
|
||||
static void ivybridge_disable_vblank(struct drm_device *dev, int pipe)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
unsigned long irqflags;
|
||||
@ -1728,7 +1728,7 @@ repeat:
|
||||
|
||||
/* drm_dma.h hooks
|
||||
*/
|
||||
void ironlake_irq_preinstall(struct drm_device *dev)
|
||||
static void ironlake_irq_preinstall(struct drm_device *dev)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
|
||||
@ -1740,7 +1740,7 @@ void ironlake_irq_preinstall(struct drm_device *dev)
|
||||
INIT_WORK(&dev_priv->rps_work, gen6_pm_rps_work);
|
||||
|
||||
I915_WRITE(HWSTAM, 0xeffe);
|
||||
if (IS_GEN6(dev)) {
|
||||
if (IS_GEN6(dev) || IS_GEN7(dev)) {
|
||||
/* Workaround stalls observed on Sandy Bridge GPUs by
|
||||
* making the blitter command streamer generate a
|
||||
* write to the Hardware Status Page for
|
||||
@ -1769,7 +1769,7 @@ void ironlake_irq_preinstall(struct drm_device *dev)
|
||||
POSTING_READ(SDEIER);
|
||||
}
|
||||
|
||||
int ironlake_irq_postinstall(struct drm_device *dev)
|
||||
static int ironlake_irq_postinstall(struct drm_device *dev)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
/* enable kind of interrupts always enabled */
|
||||
@ -1841,7 +1841,7 @@ int ironlake_irq_postinstall(struct drm_device *dev)
|
||||
return 0;
|
||||
}
|
||||
|
||||
int ivybridge_irq_postinstall(struct drm_device *dev)
|
||||
static int ivybridge_irq_postinstall(struct drm_device *dev)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
/* enable kind of interrupts always enabled */
|
||||
@ -1891,7 +1891,7 @@ int ivybridge_irq_postinstall(struct drm_device *dev)
|
||||
return 0;
|
||||
}
|
||||
|
||||
void i915_driver_irq_preinstall(struct drm_device * dev)
|
||||
static void i915_driver_irq_preinstall(struct drm_device * dev)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
int pipe;
|
||||
@ -1918,7 +1918,7 @@ void i915_driver_irq_preinstall(struct drm_device * dev)
|
||||
* Must be called after intel_modeset_init or hotplug interrupts won't be
|
||||
* enabled correctly.
|
||||
*/
|
||||
int i915_driver_irq_postinstall(struct drm_device *dev)
|
||||
static int i915_driver_irq_postinstall(struct drm_device *dev)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
u32 enable_mask = I915_INTERRUPT_ENABLE_FIX | I915_INTERRUPT_ENABLE_VAR;
|
||||
@ -1994,7 +1994,7 @@ int i915_driver_irq_postinstall(struct drm_device *dev)
|
||||
return 0;
|
||||
}
|
||||
|
||||
void ironlake_irq_uninstall(struct drm_device *dev)
|
||||
static void ironlake_irq_uninstall(struct drm_device *dev)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
|
||||
@ -2014,7 +2014,7 @@ void ironlake_irq_uninstall(struct drm_device *dev)
|
||||
I915_WRITE(GTIIR, I915_READ(GTIIR));
|
||||
}
|
||||
|
||||
void i915_driver_irq_uninstall(struct drm_device * dev)
|
||||
static void i915_driver_irq_uninstall(struct drm_device * dev)
|
||||
{
|
||||
drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private;
|
||||
int pipe;
|
||||
@ -2040,3 +2040,41 @@ void i915_driver_irq_uninstall(struct drm_device * dev)
|
||||
I915_READ(PIPESTAT(pipe)) & 0x8000ffff);
|
||||
I915_WRITE(IIR, I915_READ(IIR));
|
||||
}
|
||||
|
||||
void intel_irq_init(struct drm_device *dev)
|
||||
{
|
||||
dev->driver->get_vblank_counter = i915_get_vblank_counter;
|
||||
dev->max_vblank_count = 0xffffff; /* only 24 bits of frame count */
|
||||
if (IS_G4X(dev) || IS_GEN5(dev) || IS_GEN6(dev) || IS_IVYBRIDGE(dev)) {
|
||||
dev->max_vblank_count = 0xffffffff; /* full 32 bit counter */
|
||||
dev->driver->get_vblank_counter = gm45_get_vblank_counter;
|
||||
}
|
||||
|
||||
|
||||
dev->driver->get_vblank_timestamp = i915_get_vblank_timestamp;
|
||||
dev->driver->get_scanout_position = i915_get_crtc_scanoutpos;
|
||||
|
||||
if (IS_IVYBRIDGE(dev)) {
|
||||
/* Share pre & uninstall handlers with ILK/SNB */
|
||||
dev->driver->irq_handler = ivybridge_irq_handler;
|
||||
dev->driver->irq_preinstall = ironlake_irq_preinstall;
|
||||
dev->driver->irq_postinstall = ivybridge_irq_postinstall;
|
||||
dev->driver->irq_uninstall = ironlake_irq_uninstall;
|
||||
dev->driver->enable_vblank = ivybridge_enable_vblank;
|
||||
dev->driver->disable_vblank = ivybridge_disable_vblank;
|
||||
} else if (HAS_PCH_SPLIT(dev)) {
|
||||
dev->driver->irq_handler = ironlake_irq_handler;
|
||||
dev->driver->irq_preinstall = ironlake_irq_preinstall;
|
||||
dev->driver->irq_postinstall = ironlake_irq_postinstall;
|
||||
dev->driver->irq_uninstall = ironlake_irq_uninstall;
|
||||
dev->driver->enable_vblank = ironlake_enable_vblank;
|
||||
dev->driver->disable_vblank = ironlake_disable_vblank;
|
||||
} else {
|
||||
dev->driver->irq_preinstall = i915_driver_irq_preinstall;
|
||||
dev->driver->irq_postinstall = i915_driver_irq_postinstall;
|
||||
dev->driver->irq_uninstall = i915_driver_irq_uninstall;
|
||||
dev->driver->irq_handler = i915_driver_irq_handler;
|
||||
dev->driver->enable_vblank = i915_enable_vblank;
|
||||
dev->driver->disable_vblank = i915_disable_vblank;
|
||||
}
|
||||
}
|
||||
|
@ -597,7 +597,7 @@ static void i915_restore_modeset_reg(struct drm_device *dev)
|
||||
return;
|
||||
}
|
||||
|
||||
void i915_save_display(struct drm_device *dev)
|
||||
static void i915_save_display(struct drm_device *dev)
|
||||
{
|
||||
struct drm_i915_private *dev_priv = dev->dev_private;
|
||||
|
||||
@ -678,7 +678,6 @@ void i915_save_display(struct drm_device *dev)
|
||||
}
|
||||
|
||||
/* VGA state */
|
||||
mutex_lock(&dev->struct_mutex);
|
||||
dev_priv->saveVGA0 = I915_READ(VGA0);
|
||||
dev_priv->saveVGA1 = I915_READ(VGA1);
|
||||
dev_priv->saveVGA_PD = I915_READ(VGA_PD);
|
||||
@ -688,10 +687,9 @@ void i915_save_display(struct drm_device *dev)
|
||||
dev_priv->saveVGACNTRL = I915_READ(VGACNTRL);
|
||||
|
||||
i915_save_vga(dev);
|
||||
mutex_unlock(&dev->struct_mutex);
|
||||
}
|
||||
|
||||
void i915_restore_display(struct drm_device *dev)
|
||||
static void i915_restore_display(struct drm_device *dev)
|
||||
{
|
||||
struct drm_i915_private *dev_priv = dev->dev_private;
|
||||
|
||||
@ -783,7 +781,6 @@ void i915_restore_display(struct drm_device *dev)
|
||||
else
|
||||
I915_WRITE(VGACNTRL, dev_priv->saveVGACNTRL);
|
||||
|
||||
mutex_lock(&dev->struct_mutex);
|
||||
I915_WRITE(VGA0, dev_priv->saveVGA0);
|
||||
I915_WRITE(VGA1, dev_priv->saveVGA1);
|
||||
I915_WRITE(VGA_PD, dev_priv->saveVGA_PD);
|
||||
@ -791,7 +788,6 @@ void i915_restore_display(struct drm_device *dev)
|
||||
udelay(150);
|
||||
|
||||
i915_restore_vga(dev);
|
||||
mutex_unlock(&dev->struct_mutex);
|
||||
}
|
||||
|
||||
int i915_save_state(struct drm_device *dev)
|
||||
@ -801,6 +797,8 @@ int i915_save_state(struct drm_device *dev)
|
||||
|
||||
pci_read_config_byte(dev->pdev, LBB, &dev_priv->saveLBB);
|
||||
|
||||
mutex_lock(&dev->struct_mutex);
|
||||
|
||||
/* Hardware status page */
|
||||
dev_priv->saveHWS = I915_READ(HWS_PGA);
|
||||
|
||||
@ -840,6 +838,8 @@ int i915_save_state(struct drm_device *dev)
|
||||
for (i = 0; i < 3; i++)
|
||||
dev_priv->saveSWF2[i] = I915_READ(SWF30 + (i << 2));
|
||||
|
||||
mutex_unlock(&dev->struct_mutex);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -850,6 +850,8 @@ int i915_restore_state(struct drm_device *dev)
|
||||
|
||||
pci_write_config_byte(dev->pdev, LBB, dev_priv->saveLBB);
|
||||
|
||||
mutex_lock(&dev->struct_mutex);
|
||||
|
||||
/* Hardware status page */
|
||||
I915_WRITE(HWS_PGA, dev_priv->saveHWS);
|
||||
|
||||
@ -867,6 +869,7 @@ int i915_restore_state(struct drm_device *dev)
|
||||
I915_WRITE(IER, dev_priv->saveIER);
|
||||
I915_WRITE(IMR, dev_priv->saveIMR);
|
||||
}
|
||||
mutex_unlock(&dev->struct_mutex);
|
||||
|
||||
intel_init_clock_gating(dev);
|
||||
|
||||
@ -878,6 +881,8 @@ int i915_restore_state(struct drm_device *dev)
|
||||
if (IS_GEN6(dev))
|
||||
gen6_enable_rps(dev_priv);
|
||||
|
||||
mutex_lock(&dev->struct_mutex);
|
||||
|
||||
/* Cache mode state */
|
||||
I915_WRITE (CACHE_MODE_0, dev_priv->saveCACHE_MODE_0 | 0xffff0000);
|
||||
|
||||
@ -891,6 +896,8 @@ int i915_restore_state(struct drm_device *dev)
|
||||
for (i = 0; i < 3; i++)
|
||||
I915_WRITE(SWF30 + (i << 2), dev_priv->saveSWF2[i]);
|
||||
|
||||
mutex_unlock(&dev->struct_mutex);
|
||||
|
||||
intel_i2c_reset(dev);
|
||||
|
||||
return 0;
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user