Since get_settings() returns a signed int and it gets checked
for < 0 to catch an error, res should be a signed int too.
Signed-off-by: Eric Sesterhenn <[email protected]>
Signed-off-by: Alexey Dobriyan <[email protected]>
Signed-off-by: Jeff Garzik <[email protected]>
Make phy 0 actually be read, as it is not being right now as we have:
int mii_status = mdio_read(dev, phy, MII_BMSR);
int phyx = phy & 0x1f;
When we should have instead:
int phyx = phy & 0x1f;
int mii_status = mdio_read(dev, phyx, MII_BMSR);
so that when phy, in the end of the (phy = 1; phy <= 32...) loop gets
to 32 phyx gets to 0, i.e. we were reading at 32, when the intended
read was for 0.
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
Signed-off-by: Jeff Garzik <[email protected]>
Unlike their older siblings, ICH6 and 7 use different scheme for MAP
VALUE. This patch makes ata_piix interpret MV properly on ICH6/7.
Pre-ICH6/7
The value of these bits indicate the address range the SATA port
responds to, and whether or not the SATA and IDE functions are
combined.
000 = Non-combined. P0 is primary master. P1 is secondary master.
001 = Non-combined. P0 is secondary master. P1 is primary master.
100 = Combined. P0 is primary master. P1 is primary slave. P-ATA is
2:0 Map Value secondary.
101 = Combined. P0 is primary slave. P1 is primary master. P-ATA is
secondary.
110 = Combined. P-ATA is primary. P0 is secondary master. P1 is
secondary slave.
111 = Combined. P-ATA is primary. P0 is secondary slave. P1 is
secondary master.
ICH6/7
Map Value - R/W. Map Value (MV): The value in the bits below indicate
the address range the SATA ports responds to, and whether or not the
PATA and SATA functions are combined. When in combined mode, the AHCI
memory space is not available and AHCI may not be used.
00 = Non-combined. P0 is primary master, P2 is the primary slave. P1
is secondary master, P3 is the 1:0 secondary slave (desktop
only). P0 is primary master, P2 is the primary slave (mobile
only).
01 = Combined. IDE is primary. P1 is secondary master, P3 is the
secondary slave. (desktop only)
10 = Combined. P0 is primary master. P2 is primary slave. IDE is secondary
11 = Reserved
Signed-off-by: Tejun Heo <[email protected]>
--
Jeff, without this patch, ata_piix misdetects my ICH7's combined mode,
ending up not applying bridge limits to PX-710SA and configuring IDE
drive on 40-c cable to UDMA/66.
Thanks.
Signed-off-by: Jeff Garzik <[email protected]>
On SN2, MMIO writes which are issued from separate processors are not
guaranteed to arrive in any particular order at the IO hardware. When
performing such writes from the kernel this is not a problem, as a
kernel thread will not migrate to another CPU during execution, and
mmiowb() calls can guarantee write ordering when control of the IO
resource is allowed to move between threads.
However, when MMIO writes can be performed from user space (e.g. DRM)
there are no such guarantees and mechanisms, as the process may
context-switch at any time, and may migrate to a different CPU as part
of the switch. For such programs/hardware to operate correctly, it is
required that the MMIO writes from the old CPU be accepted by the IO
hardware before subsequent writes from the new CPU can be issued.
The following patch implements this behavior on SN2 by waiting for a
Shub register to indicate that these writes have been accepted. This
is placed in the context switch-in path, and only performs the wait
when the newly scheduled task changes CPUs.
Signed-off-by: Prarit Bhargava <[email protected]>
Signed-off-by: Brent Casavant <[email protected]>
This patch finishes support for SHUB2 (the new chipset). Most of the
changes are performance related. A few changes are workarounds for
"interesting" chipset features.
Some temporary debugging code has also been deleted.
Signed-off-by: Jack Steiner <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
In the case where a (broken) BIOS gives us a blank _CRS for
a PCI Interrupt Link Device, the acpi_walk_resources()
will not terminate, but will then give the callback
the resource end tag. Ignore the end tag.
Signed-off-by: Len Brown <[email protected]>
Various bugfixes and hardware bug workarounds necessary for the rev 1.0 version
of the altix TIO CE asic.
Signed-off-by: Mark Maule <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
Handle system controller power down pending events
on SN systems. This allows the system to gracefully shutdown
before the system controller removes power due to
an adverse environmental condition.
Signed-off-by: Aaron Young <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
The only user of the MCA/INIT sigdelayed code (SGI's I/O probing) has
moved from the kernel into SAL. Delete the MCA/INIT sigdelayed code.
Signed-off-by: Keith Owens <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
Actually I think this is more appropriate so we don't end up with 17
cases that add drivers/sn to the build lib.
Include drivers/sn when CONFIG_IA64_SGI_SN2 or CONFIG_IA64_GENERIC
is enabled.
Acked-by: Dave Jones <[email protected]>
Signed-off-by: Jes Sorensen <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
arch/ia64/sn/Makefile sets CPPFLAGS, expecting that setting to
propogate to all the subdirectories. For a normal build with its
recursive descent it does work, but doing a selective build like
'make arch/ia64/sn/kernel/io_init.i' does not do a recursive descent,
it goes directly to arch/ia64/sn/kernel/Makefile so the flags do not
get set.
To support selective builds, set the flags in all the subordinate Makefiles.
Signed-off-by: Keith Owens <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
Convert to use a single mutex instead of two rwsems as this isn't
performance critical.
Signed-off-by: Jes Sorensen <[email protected]>
Signed-off-by: Brent Casavant <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
Implement ia64 optimized mutex primitives. It properly uses
acquire/release memory ordering semantics in lock/unlock path.
2nd version making them all static inline functions.
Signed-off-by: Ken Chen <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
When the scsi_execute_async interface was added it ended up reducing
the flexibility of userspace to send arbitrary scsi commands through
sg using SG_IO. The SG_IO interface allows userspace to specify the
CDB length. This is now ignored in scsi_execute_async and it is
guessed using the COMMAND_SIZE macro, which is not always correct,
particularly for vendor specific commands. This patch adds a cmd_len
parameter to the scsi_execute_async interface to allow the caller
to specify the length of the CDB.
Signed-off-by: Brian King <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
BIOS might change frequency behind our back when BIOS changes allowed
frequencies via _PPC. In this case cpufreq core got out of sync.
Ask driver for current freq and notify governors about a change
Signed-off-by: Thomas Renninger <[email protected]>
Signed-off-by: Venkatesh Pallipadi <[email protected]>
Signed-off-by: Dave Jones <[email protected]>
Ignore clock frequencies below 2Ghz for CPU's detected with N60 errata bug.
Signed-off-by: Ben Collins <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Dave Jones <[email protected]>
Patch from George G. Davis
This Freescale Semiconductor, Inc. contributed patch adds mem_types[]
support for ARMv6 non-shared device memory region attributes. This
implementation provides support for only first level section mapped
non-shared devices. Second level non-shared device mappings are not
yet supported.
Signed-off-by: George G. Davis <[email protected]>
Signed-off-by: Russell King <[email protected]>
Patch from Lucas Correia Villa Real
This patch defines S3C2400 memory map and adds a S3C24XX macro for
common resources between S3C2400, S3C2410 and S3C2440 cpus.
Signed-off-by: Lucas Correia Villa Real <[email protected]>
Signed-off-by: Ben Dooks <[email protected]>
Signed-off-by: Russell King <[email protected]>
Some folk want to use RGB555 rather tahn RGB565 with amba-clcd.
Allow amba-clcd to accept either pixel format.
Signed-off-by: Russell King <[email protected]>
Resetting the adapter causes the ServeRAID driver to exceed
the max time allowed by the softlock watchdog. Resetting the
hardware can easily require 30 or more seconds. To avoid the
"BUG: soft lockup detected on CPU#0!"
result, this patch replaces the mdelay() calls in the
initialization/reset routines with msleep().
Signed-off-by: Jack Hammer <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
Internal lun discovery has been removed since fc_transport
integration. Short-circuiting for tape-devices in
qla2x00_update_fcport() could inadvertently result in a
blocked rport timing-out and its targets being reaped.
Signed-off-by: Andrew Vasquez <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
A target can LOGO an initiator at any time (i.e. during I/O,
due to a controller hicup, or as a simple authentication
mechanism after an initial CDB command), when this occurs,
the driver attempts to relogin (PLOGI) to the device via the
DPC thread. Add code to make the appropriate upcall to the
FC transport layer (fc_remote_port_add()) upon successful
completion of the PLOGI.
Signed-off-by: Andrew Vasquez <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
The driver can typically detect port-loss during an
interrupt context (i.e. via interrogation of a status IOCB's
completion status [CS_PORT_LOGGED_OUT]. Due to the calling
requirements of the fc_rport APIs, the driver would defer
removal of the device to the default workqueue. If the
work-item was preceded by an event which caused the port to
obtain visibility (relogin successful, target re-logged into
the topology), deferred removal could inadvertently drop the
rport. The code also no longer defers removal via the
default workqueue, instead opting for use of the driver's
own DPC thread.
Signed-off-by: Andrew Vasquez <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
The patch below "fixes" calculation of the virt_addr for the AUTO_REQSENSE
case. I put "fixes" in quotes because the real fix would be to completely
remove it, but that's beyond the scope of this patch.
Signed-off-by: Guennadi Liakhovetski <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
New versions of the Power5 firmware can send a "re-enable" message to
the virtual scsi adapter. This fix makes us handle the message
correctly. Without it, the driver goes catatonic and the system crashes
unpleasantly.
Signed-off-by: Dave Boutcher <[email protected]>
Signed-off-by: James Bottomley <[email protected]>
memset clears once set structure, there is actually no need for memset,
because configure function do it for us. Next, vfree(NULL) is legal, so
avoid useless labels.
Thanks Dave Jones for reporting this.
Signed-off-by: Jiri Slaby <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
memset clears once set structure, there is actually no need for memset,
because configure function do it for us. Next, vfree(NULL) is legal, so
avoid useless labels.
Thanks Dave Jones for reporting this.
Signed-off-by: Jiri Slaby <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
Fixes the following sparse warnings:
drivers/char/drm/via_dmablit.c:111:35: warning: Using plain integer as NULL pointer
drivers/char/drm/via_dmablit.c:584:23: warning: Using plain integer as NULL pointer
Signed-off-by: Luiz Capitulino <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
After the recent overhaul of the block layer the variable
"ordered_flush" is no longer used.
Signed-off-by: Tetsuo Takata <[email protected]>
Signed-off-by: Jens Axboe <[email protected]>
Fix CMDBUFFER path, add heap destroy and flesh out sarea for rotation
(Tungsten Graphics)
From: Alan Hourihane <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
typically - header + 13 pages).
Forgetting to set wsize on the mount command costs more than 10% on large
write (can be much more) so this makes a saner default. We still shrink
this default smaller if server can not support it.
Signed-off-by: Steve French <[email protected]>
From: Randy Dunlap <[email protected]>
Use NULL instead of 0 (sparse warnings):
drivers/char/drm/ati_pcigart.c:64:10: warning: Using plain integer as NULL
pointer
drivers/char/drm/ati_pcigart.c:130:21: warning: Using plain integer as NULL
pointer
drivers/char/drm/ati_pcigart.c:171:14: warning: Using plain integer as NULL
pointer
Signed-off-by: Randy Dunlap <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
From: Brice Goglin <[email protected]>
Now that Xorg 6.9/7.0 has been released, DRI is supported on more Radeon
cards without ATI proprietary drivers. I got my X300 to work without
problem. But, another Radeon X600 required to add its PCI ids to the
Radeon driver. Patch is attached.
I can't be sure about the "CHIP_RV350", I copied it from the X300 entry
(from http://dri.freedesktop.org/wiki/ATIRadeon, X600 is a rv380 chip while
X300 is a rv370). But, at least it works now.
Signed-off-by: Brice Goglin <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
We lured Jes to the dark side, and he's going to take over as the sn2
maintainer. His experience and thoroughness will serve him well here.
Signed-off-by: Greg Edwards <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
SGI's prom has added a new feature which avoids an Altix-specific
MCA that can occur with excessive use of ia64_pal_cache_flush. This
patch adds the #define to the sn_feature_sets.h to reflect that bit
is taken.
Signed-off-by: Dean Roe <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
Eliminate a hot shared cacheline that occurs if multiple cpus are
taking unaligned exceptions.
Signed-off-by: Jack Steiner <[email protected]>
Signed-off-by: Tony Luck <[email protected]>
Takashi helped us track down a bad page state bug we thought was coming
from alsa. It turns out we weren't paying attention to the gfp flags
that were passed in to sn_dma_alloc_coherent().
From: Takashi Iwai <[email protected]>
Signed-off-by: Greg Edwards <[email protected]>
Signed-off-by: Mark Maule <[email protected]>
Signed-off-by: Jes Sorensen <[email protected]>
the conversion was generated via scripts, and the result was validated
automatically via a script as well.
build and boot tested.
Signed-off-by: Ingo Molnar <[email protected]>
Signed-off-by: Dave Kleikamp <[email protected]>
The following patch fixes these problems in MLDv2:
1) Add/remove "delete" records for sending change reports when
addition of a filter results in that filter transitioning to/from
inactive. [same as recent IPv4 IGMPv3 fix]
2) Remove 2 redundant "group_type" checks (can't be IPV6_ADDR_ANY
within that loop, so checks are always true)
3) change an is_in() "return 0" to "return type == MLD2_MODE_IS_INCLUDE".
It should always be "0" to get here, but it improves code locality
to not assume it, and if some race allowed otherwise, doing
the check would return the correct result.
Signed-off-by: David L Stevens <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
When returning a message to userspace in reply to a SADB_FLUSH or
SADB_X_SPDFLUSH message, the type was not set for the returned PFKEY
message. The patch below corrects this problem.
Signed-off-by: Jerome Borsboom <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
This information is already available via /proc/net/bonding/*
therefore it doesn't make sense to require CAP_NET_ADMIN
privileges.
Original patch by Laurent Deniel <[email protected]>
Signed-off-by: Thomas Graf <[email protected]>
Signed-off-by: David S. Miller <[email protected]>