id stringlengths 40 40 | instruction stringlengths 68 308 | input stringlengths 17 33.4k | output stringlengths 100 30k |
|---|---|---|---|
e29bfbc44332ee2233d87d5adfd1824fd8a1c73b | Analyze and fix the following issue in the Linux kernel code: sh: intc - add support for SH7760 | Problem Details:
This patch converts the cpu specific interrupt setup code for sh7760
from ipr + intc2 to intc. New vectors are also added to match the
information provided by the datasheet.
Vectors for IRQ4-IRQ7 are enabled by default. Use plat_irq_setup_pins()
if pins IRL0-3 should be used in IRLM mode.
The patch a... | ```diff
diff --git a/arch/sh/kernel/cpu/sh4/setup-sh7760.c b/arch/sh/kernel/cpu/sh4/setup-sh7760.c
index 47fa27056253..6a6686d71fbc 100644
--- a/arch/sh/kernel/cpu/sh4/setup-sh7760.c
+++ b/arch/sh/kernel/cpu/sh4/setup-sh7760.c
@@ -12,6 +12,136 @@
#include <linux/serial.h>
#include <asm/sci.h>
+enum {
+ UNUSED = 0,
... |
f216cc3748a3a22c2b99390fddcdafa0583791a2 | Analyze and fix the following issue in the Linux kernel code: ACPI: suspend: consolidate handling of Sx states. | Problem Details:
Recent changes to sleep initialization in ACPI dropped reporting of supported Sx
states above S3. Fix that and also move S5 init into same file as other Sx.
The only functional change is adding printk() for S4 and S5 cases.
Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
Acked-by: Rafael J.... | ```diff
diff --git a/drivers/acpi/sleep/Makefile b/drivers/acpi/sleep/Makefile
index 195a4f69c0f7..ba9bd403d443 100644
--- a/drivers/acpi/sleep/Makefile
+++ b/drivers/acpi/sleep/Makefile
@@ -1,4 +1,4 @@
-obj-y := poweroff.o wakeup.o
+obj-y := wakeup.o
obj-$(CONFIG_ACPI_SLEEP) += main.o
obj-$(CONFIG_ACPI_SLEE... |
db56246c6980e376b02d2da568d119da71f82fb9 | Analyze and fix the following issue in the Linux kernel code: ocfs2: Fix pos/len passed to ocfs2_write_cluster | Problem Details:
This was broken for file systems whose cluster size is greater than page
size. Pos needs to be incremented as we loop through the descriptors, and
len needs to be capped to the size of a single cluster.
Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com> | ```diff
diff --git a/fs/ocfs2/aops.c b/fs/ocfs2/aops.c
index 50cd8a209012..fa43810e5970 100644
--- a/fs/ocfs2/aops.c
+++ b/fs/ocfs2/aops.c
@@ -1211,18 +1211,33 @@ static int ocfs2_write_cluster_by_desc(struct address_space *mapping,
loff_t pos, unsigned len)
{
int ret, i;
+ loff_t cluster_off;
+ unsigned... |
415cb800375cc4e89fb5a6a454e484bd4adbffb4 | Analyze and fix the following issue in the Linux kernel code: ocfs2: Allow smaller allocations during large writes | Problem Details:
The ocfs2 write code loops through a page much like the block code, except
that ocfs2 allocation units can be any size, including larger than page
size. Typically it's equal to or larger than page size - most kernels run 4k
pages, the minimum ocfs2 allocation (cluster) size.
Some changes introduced du... | ```diff
diff --git a/fs/ocfs2/file.c b/fs/ocfs2/file.c
index 7e34e66159c6..f3bc3658e7a5 100644
--- a/fs/ocfs2/file.c
+++ b/fs/ocfs2/file.c
@@ -491,8 +491,8 @@ int ocfs2_do_extend_allocation(struct ocfs2_super *osb,
goto leave;
}
- status = ocfs2_claim_clusters(osb, handle, data_ac, 1,
- &bit_off, &num_b... |
ed2ba977d43a6031f78f9e49d739ef5094f512e4 | Analyze and fix the following issue in the Linux kernel code: [PATCH] missing null termination in power supply uevent | Problem Details:
Need to null terminate environment. Found by inspection
while looking for similar problems to platform uevent bug
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org> | ```diff
diff --git a/drivers/power/power_supply_sysfs.c b/drivers/power/power_supply_sysfs.c
index c7c4574729b1..de3155b21285 100644
--- a/drivers/power/power_supply_sysfs.c
+++ b/drivers/power/power_supply_sysfs.c
@@ -289,6 +289,7 @@ int power_supply_uevent(struct device *dev, char **envp, int num_envp,
if (ret)
... |
9db619e66503494e41159de3c76fafabe80d016b | Analyze and fix the following issue in the Linux kernel code: rpc: fix garbage in printk in svc_tcp_accept() | Problem Details:
we upgraded the kernel of a nfs-server from 2.6.17.11 to 2.6.22.6. Since
then we get the message
lockd: too many open TCP sockets, consider increasing the number of nfsd threads
lockd: last TCP connect from ^\\236^\É^D
These random characters in the second line are caused by a bug in
svc_tcp_accept.
... | ```diff
diff --git a/net/sunrpc/svcsock.c b/net/sunrpc/svcsock.c
index 1a899924023f..036ab520df21 100644
--- a/net/sunrpc/svcsock.c
+++ b/net/sunrpc/svcsock.c
@@ -1110,7 +1110,8 @@ svc_tcp_accept(struct svc_sock *svsk)
serv->sv_name);
printk(KERN_NOTICE
"%s: last TCP connect from %s\n",
- ... |
e1cc9de8361f267101402a1181cff4d3d3225a6d | Analyze and fix the following issue in the Linux kernel code: libata-sff: Fix documentation | Problem Details:
Code moved to ioread/iowrite but the comment didn't
Also note a posting issue
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org> | ```diff
diff --git a/drivers/ata/libata-sff.c b/drivers/ata/libata-sff.c
index 1cce2198baaf..8023167bbbeb 100644
--- a/drivers/ata/libata-sff.c
+++ b/drivers/ata/libata-sff.c
@@ -297,7 +297,7 @@ void ata_bmdma_start (struct ata_queued_cmd *qc)
dmactl = ioread8(ap->ioaddr.bmdma_addr + ATA_DMA_CMD);
iowrite8(dmactl |... |
75e806838a3327d4ca9030e588d34de11b04f341 | Analyze and fix the following issue in the Linux kernel code: sky2: receive FIFO checking | Problem Details:
A driver writer from another operating system hinted that
the versions of Yukon 2 chip with rambuffer (EC and XL) have
a hardware bug that if the FIFO ever gets completely full it
will hang. Sounds like a classic ring full vs ring empty wrap around
bug.
As a workaround, use the existing watchdog timer... | ```diff
diff --git a/drivers/net/sky2.c b/drivers/net/sky2.c
index d0e5875628e9..2831f44e6270 100644
--- a/drivers/net/sky2.c
+++ b/drivers/net/sky2.c
@@ -1648,9 +1648,6 @@ static int sky2_down(struct net_device *dev)
if (netif_msg_ifdown(sky2))
printk(KERN_INFO PFX "%s: disabling interface\n", dev->name);
- if ... |
c99210b50fe741026d86fdcb5f3f5a0c00c503cc | Analyze and fix the following issue in the Linux kernel code: sky2: ethtool speed report bug | Problem Details:
On 100mbit versions, the driver always reports gigabit speed
available. The correct modes are already computed, then overwritten.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
Signed-off-by: Jeff Garzik <jeff@garzik.org> | ```diff
diff --git a/drivers/net/sky2.c b/drivers/net/sky2.c
index 8b1565453f08..94552cc4c462 100644
--- a/drivers/net/sky2.c
+++ b/drivers/net/sky2.c
@@ -2841,13 +2841,6 @@ static int sky2_get_settings(struct net_device *dev, struct ethtool_cmd *ecmd)
ecmd->supported = sky2_supported_modes(hw);
ecmd->phy_address =... |
d6532232cd3de79c852685823a9c52f723816d0a | Analyze and fix the following issue in the Linux kernel code: sky2: fix VLAN receive processing (resend) | Problem Details:
The length check for truncated frames was not correctly handling
the case where VLAN acceleration had already read the tag.
Also, the Yukon EX has some features that use high bit of status
as security tag.
Signed-off-by: Pierre-Yves Ritschard <pyr@spootnik.org>
Signed-off-by: Stephen Hemminger <shemmi... | ```diff
diff --git a/drivers/net/sky2.c b/drivers/net/sky2.c
index 5d812de65d90..8b1565453f08 100644
--- a/drivers/net/sky2.c
+++ b/drivers/net/sky2.c
@@ -2103,6 +2103,13 @@ static struct sk_buff *sky2_receive(struct net_device *dev,
struct sky2_port *sky2 = netdev_priv(dev);
struct rx_ring_info *re = sky2->rx_rin... |
be7963b7e7f08a149e247c0bf29a4abd174e0929 | Analyze and fix the following issue in the Linux kernel code: ieee1394: ohci1394: fix initialization if built non-modular | Problem Details:
Initialization of ohci1394 was broken according to one reporter if the
driver was statically linked, i.e. not built as loadable module. Dmesg:
PCI: Device 0000:02:07.0 not available because of resource collisions
ohci1394: Failed to enable OHCI hardware.
This was reported for a Toshiba Satellite... | ```diff
diff --git a/drivers/ieee1394/ieee1394_core.c b/drivers/ieee1394/ieee1394_core.c
index ee45259573c8..98fd985a32ff 100644
--- a/drivers/ieee1394/ieee1394_core.c
+++ b/drivers/ieee1394/ieee1394_core.c
@@ -1273,7 +1273,7 @@ static void __exit ieee1394_cleanup(void)
unregister_chrdev_region(IEEE1394_CORE_DEV, 256... |
f3d5e3a4155b6f42f6f6f0a2cc95ca0adbabe1af | Analyze and fix the following issue in the Linux kernel code: [PPP] L2TP: Fix skb handling in pppol2tp_xmit | Problem Details:
This patch makes pppol2tp_xmit call skb_cow_head so that we don't modify
cloned skb data. It also gets rid of skb2 we only need to preserve the
original skb for congestion notification, which is only applicable for
ppp_async and ppp_sync.
The other semantic change made here is the removal of socket a... | ```diff
diff --git a/drivers/net/pppol2tp.c b/drivers/net/pppol2tp.c
index 440e190778a1..abe91cb595f4 100644
--- a/drivers/net/pppol2tp.c
+++ b/drivers/net/pppol2tp.c
@@ -962,7 +962,6 @@ static int pppol2tp_xmit(struct ppp_channel *chan, struct sk_buff *skb)
int data_len = skb->len;
struct inet_sock *inet;
__wsum... |
7a70e39b6633ad85936b029463134ee2599600f1 | Analyze and fix the following issue in the Linux kernel code: [PPP] L2TP: Fix skb handling in pppol2tp_recv_core | Problem Details:
The function pppol2tp_recv_core doesn't handle non-linear packets properly.
It also fails to check the remote offset field.
This patch fixes these problems. It also removes an unnecessary check on
the UDP header which has already been performed by the UDP layer.
Signed-off-by: Herbert Xu <herbert@go... | ```diff
diff --git a/drivers/net/pppol2tp.c b/drivers/net/pppol2tp.c
index ed8ead432d77..440e190778a1 100644
--- a/drivers/net/pppol2tp.c
+++ b/drivers/net/pppol2tp.c
@@ -491,44 +491,46 @@ static int pppol2tp_recv_core(struct sock *sock, struct sk_buff *skb)
u16 hdrflags;
u16 tunnel_id, session_id;
int length;
- ... |
21d0c83302fb742b7ffb6089d40196166102f5ed | Analyze and fix the following issue in the Linux kernel code: [PPP] pppoe: Fix double-free on skb after transmit failure | Problem Details:
When I got rid of the second packet in __pppoe_xmit I created
a double-free on the skb because of the goto abort on failure.
This patch removes that.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/drivers/net/pppoe.c b/drivers/net/pppoe.c
index 0d7f570b9a54..9b30cd600a64 100644
--- a/drivers/net/pppoe.c
+++ b/drivers/net/pppoe.c
@@ -879,8 +879,7 @@ static int __pppoe_xmit(struct sock *sk, struct sk_buff *skb)
dev->hard_header(skb, dev, ETH_P_PPP_SES,
po->pppoe_pa.remote, NULL, data_le... |
5588b40d7c2bff75ee573ed42d1738c73ce24492 | Analyze and fix the following issue in the Linux kernel code: [PKT_SCHED]: Fix 'SFQ qdisc crashes with limit of 2 packets' | Problem Details:
Acked-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/net/sched/sch_sfq.c b/net/sched/sch_sfq.c
index 957957309859..3a23e30bc79e 100644
--- a/net/sched/sch_sfq.c
+++ b/net/sched/sch_sfq.c
@@ -270,7 +270,7 @@ sfq_enqueue(struct sk_buff *skb, struct Qdisc* sch)
q->tail = x;
}
}
- if (++sch->q.qlen < q->limit-1) {
+ if (++sch->q.qlen <= q->limit... |
29c5d4afba51c71cfeadd3f74f3c42e064483fb0 | Analyze and fix the following issue in the Linux kernel code: [NETFILTER]: nfnetlink_log: fix sending of multipart messages | Problem Details:
The following patch fixes the handling of netlink packets containing
multiple messages.
As exposed during netfilter workshop, nfnetlink_log was overwritten the
message type of the last message (setting it to MSG_DONE) in a multipart
packet. The consequence was libnfnetlink to ignore the last message i... | ```diff
diff --git a/net/netfilter/nfnetlink_log.c b/net/netfilter/nfnetlink_log.c
index e185a5b55913..2351533a8507 100644
--- a/net/netfilter/nfnetlink_log.c
+++ b/net/netfilter/nfnetlink_log.c
@@ -58,7 +58,6 @@ struct nfulnl_instance {
unsigned int qlen; /* number of nlmsgs in skb */
struct sk_buff *skb; /* p... |
6d0b842d3bf0cc027dcff57a89fb8a6b1fd610e1 | Analyze and fix the following issue in the Linux kernel code: Fix CRLF line endings in Documentation/input/iforce-protocol.txt | Problem Details:
Emil Medve points out that this documentation file uses CRLF line
endings, which means that if you use
[core]
autocrlf=input
(which makes sense if you ever develop under Windows, for example, or if
you use other broken tools) in your git config, git will always complain
about the file being dirty.... | ```diff
diff --git a/Documentation/input/iforce-protocol.txt b/Documentation/input/iforce-protocol.txt
index 95df4ca70e71..8777d2d321e3 100644
--- a/Documentation/input/iforce-protocol.txt
+++ b/Documentation/input/iforce-protocol.txt
@@ -1,254 +1,254 @@
-** Introduction
-This document describes what I managed to disco... |
bbc15f46fe4dc2862325e2b4ba474a854162e1a1 | Analyze and fix the following issue in the Linux kernel code: [x86 setup] Fix typo in arch/i386/boot/header.S | Problem Details:
There's an obvious typo in arch/i386/boot/header.S (in your
linux-2.6-x86setup.git) that I noticed by just studying the code.
Signed-off-by: Paul Bolle <pebolle@tiscali.nl>
Signed-off-by: H. Peter Anvin <hpa@zytor.com> | ```diff
diff --git a/arch/i386/boot/header.S b/arch/i386/boot/header.S
index 7f4a2c53bd76..f3140e596d40 100644
--- a/arch/i386/boot/header.S
+++ b/arch/i386/boot/header.S
@@ -275,7 +275,7 @@ die:
hlt
jmp die
- .size die, .-due
+ .size die, .-die
.section ".initdata", "a"
setup_corrupt:
``` |
91c4b8cb5ab8cc3e8352739e35699c0487a6b6f3 | Analyze and fix the following issue in the Linux kernel code: [acpi] Correct the decoding of video mode numbers in wakeup.S | Problem Details:
wakeup.S looks at the video mode number from the setup header and
looks to see if it is a VESA mode. Unfortunately, the decoding is
done incorrectly and it will attempt to frob the VESA BIOS for any
mode number 0x0200 or larger. Correct this, and remove a bunch of #if
0'd code.
Massive thanks to Jef... | ```diff
diff --git a/arch/i386/kernel/acpi/wakeup.S b/arch/i386/kernel/acpi/wakeup.S
index ed0a0f2c1597..f22ba8534d26 100644
--- a/arch/i386/kernel/acpi/wakeup.S
+++ b/arch/i386/kernel/acpi/wakeup.S
@@ -151,51 +151,30 @@ bogus_real_magic:
#define VIDEO_FIRST_V7 0x0900
# Setting of user mode (AX=mode ID) => CF=succe... |
f604931238dff7b44ef52ac2ad1f557e45b25b38 | Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: abstract debug card setup (smc, leds) | Problem Details:
Additional cleanup for debug boards on H2/P2/H3/H4: move the init
code that's not board-specific into a new file where it can be easily
shared between all the different boards (avoiding code duplication,
and making it easier to support more devices). Make H4 use that.
This should be easy to drop in ... | ```diff
diff --git a/arch/arm/mach-omap2/Kconfig b/arch/arm/mach-omap2/Kconfig
index 7393109f5c30..cf4268e46b03 100644
--- a/arch/arm/mach-omap2/Kconfig
+++ b/arch/arm/mach-omap2/Kconfig
@@ -21,7 +21,7 @@ config MACH_OMAP_GENERIC
config MACH_OMAP_H4
bool "OMAP 2420 H4 board"
depends on ARCH_OMAP2 && ARCH_OMAP24XX
... |
1c22cc13256046162bb8e7b44763f6c39790af74 | Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: omap2/gpmc updates | Problem Details:
GPMC updates:
- bugfixes: wrong/missing flags, omitted write, wrong test
- don't map memory segments starting at zero
- improve debug messaging
- export gpmc_get_fclk_perio]d() since it's needed to calc timings
- expect gpmc_cs_set_timings() caller to have initialized sync vs async
Note that this... | ```diff
diff --git a/arch/arm/mach-omap2/gpmc.c b/arch/arm/mach-omap2/gpmc.c
index e290b989aa94..6d6b25c46b1f 100644
--- a/arch/arm/mach-omap2/gpmc.c
+++ b/arch/arm/mach-omap2/gpmc.c
@@ -88,7 +88,7 @@ u32 gpmc_cs_read_reg(int cs, int idx)
}
/* TODO: Add support for gpmc_fck to clock framework and use it */
-static ... |
742c53e48e5f8e05ec9f0818281fada9c6061023 | Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: omap2/memory.c compile fixes | Problem Details:
Remove some conflicting declarations in omap2/memory.c so that the
file builds again.
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Tony Lindgren <tony@atomide.com> | ```diff
diff --git a/arch/arm/mach-omap2/memory.c b/arch/arm/mach-omap2/memory.c
index f173aa8d896f..3e5d8cd4ea4f 100644
--- a/arch/arm/mach-omap2/memory.c
+++ b/arch/arm/mach-omap2/memory.c
@@ -30,37 +30,6 @@
#include "prcm-regs.h"
#include "memory.h"
-#define SMS_BASE 0x68008000
-#define SMS_SYSCONFIG 0x010
-
-... |
f024840872e76b1fdef324aee8c9176ed7aa0ba4 | Analyze and fix the following issue in the Linux kernel code: ARM: OMAP: Board Apollon update, fix boot | Problem Details:
Update Apollon board init to initialize NAND, USB,
and LEDs. Also configure GPMC memory for smc91x Ethernet.
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Tony Lindgren <tony@atomide.com> | ```diff
diff --git a/arch/arm/mach-omap2/board-apollon.c b/arch/arm/mach-omap2/board-apollon.c
index 878ff9181d0e..3bb49c17c858 100644
--- a/arch/arm/mach-omap2/board-apollon.c
+++ b/arch/arm/mach-omap2/board-apollon.c
@@ -25,6 +25,8 @@
#include <linux/irq.h>
#include <linux/interrupt.h>
#include <linux/delay.h>
+#i... |
2224f4e5d5317552d48ce9059761148b1516ba5d | Analyze and fix the following issue in the Linux kernel code: [CIFS] fix typo in previous commit | Problem Details:
Signed-off-by: Steve French <sfrench@us.ibm.com> | ```diff
diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c
index 73ed9fcab821..5c3cc6487e59 100644
--- a/fs/cifs/connect.c
+++ b/fs/cifs/connect.c
@@ -1750,7 +1750,7 @@ void reset_cifs_unix_caps(int xid, struct cifsTconInfo *tcon,
"mounting with the Unix Extensions\n"
"disabled, if problems are found,... |
c4d5e375470862fd741f93bf0686d7ac2f7fdce4 | Analyze and fix the following issue in the Linux kernel code: [POWERPC] Cleanups for physmap_of.c (v2) | Problem Details:
This patch includes a whole batch of smallish cleanups for
drivers/mtd/physmap_of.c.
- A bunch of uneeded #includes are removed
- We switch to the modern linux/of.h etc. in place of
asm/prom.h
- Use some helper macros to avoid some ugly inline #ifdefs
- A few lines of unreachable code are removed
... | ```diff
diff --git a/drivers/mtd/maps/physmap_of.c b/drivers/mtd/maps/physmap_of.c
index 096dd47b5d5d..cf75a566442e 100644
--- a/drivers/mtd/maps/physmap_of.c
+++ b/drivers/mtd/maps/physmap_of.c
@@ -1,5 +1,5 @@
/*
- * Normal mappings of chips in physical memory for OF devices
+ * Flash mappings described by the OF (or... |
bd0076cc330f303905018a17d9dcfbabde497572 | Analyze and fix the following issue in the Linux kernel code: [POWERPC] 4xx: Fix Sequoia MAL0 and EMAC dts entries. | Problem Details:
According to PowerPC 440EPx documentation,
MAL0 is comprised of four channels (two transmit and two receive).
Each channel is dedicated to one of two EMAC cores.
This patch fixes Sequoia DTS MAL0 entry and EMAC entries,
assigning correct channel numbers to EMACs.
Signed-off-by: Valentine Barshak <vbar... | ```diff
diff --git a/arch/powerpc/boot/dts/sequoia.dts b/arch/powerpc/boot/dts/sequoia.dts
index b236798ce812..36be75b04de1 100644
--- a/arch/powerpc/boot/dts/sequoia.dts
+++ b/arch/powerpc/boot/dts/sequoia.dts
@@ -107,8 +107,8 @@
MAL0: mcmal {
compatible = "ibm,mcmal-440epx", "ibm,mcmal2";
dcr-reg = <180 62... |
e52f5677bf6954dbd128a2d659d77a85ced55d30 | Analyze and fix the following issue in the Linux kernel code: [POWERPC] 4xx: Fix Bamboo MAL0 dts entry. | Problem Details:
According to PowerPC 440EP documentation,
MAL0 consists of 6 channels (4 transmit channels and 2 receive channels)
This patch fixes Bamboo DTS MAL0 "num-rx-chans" entry.
Signed-off-by: Valentine Barshak <vbarshak@ru.mvista.com>
Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com> | ```diff
diff --git a/arch/powerpc/boot/dts/bamboo.dts b/arch/powerpc/boot/dts/bamboo.dts
index bdd56b0e9460..a88ae3d218a5 100644
--- a/arch/powerpc/boot/dts/bamboo.dts
+++ b/arch/powerpc/boot/dts/bamboo.dts
@@ -94,7 +94,7 @@
compatible = "ibm,mcmal-440ep", "ibm,mcmal-440gp", "ibm,mcmal";
dcr-reg = <180 62>;
... |
1bc5858d0d40e07697b5eda47ed8628b8a934235 | Analyze and fix the following issue in the Linux kernel code: [XFS] fix valid but harmless sparse warning | Problem Details:
The new xlog_recover_do_reg_buffer checks call be16_to_cpu on di_gen which
is a 32bit value so sparse rightly complains. Fortunately the warning is
harmless because we don't care for the value, but only whether it's
non-NULL. Due to that fact we can simply kill the endian swaps on this and
the previous... | ```diff
diff --git a/fs/xfs/xfs_log_recover.c b/fs/xfs/xfs_log_recover.c
index dacb19739cc2..7174991f4bef 100644
--- a/fs/xfs/xfs_log_recover.c
+++ b/fs/xfs/xfs_log_recover.c
@@ -1920,9 +1920,9 @@ xlog_recover_do_reg_buffer(
stale_buf = 1;
break;
}
- if (be16_to_cpu(dip->di_core.di_mode))
+ if (dip->d... |
bcc7b445eff295664a3a3ab14e742b3c9d88e6e3 | Analyze and fix the following issue in the Linux kernel code: [XFS] fix filestreams on 32-bit boxes | Problem Details:
xfs_filestream_mount() sets up an mru cache with:
err = xfs_mru_cache_create(&mp->m_filestream, lifetime, grp_count,
(xfs_mru_cache_free_func_t)xfs_fstrm_free_func);
but that cast is causing problems...
typedef void (*xfs_mru_cache_free_func_t)(unsigned long, void*);
but:
void xfs_fstrm_free_fu... | ```diff
diff --git a/fs/xfs/xfs_filestream.c b/fs/xfs/xfs_filestream.c
index 16f8e175167d..36d8f6aa11af 100644
--- a/fs/xfs/xfs_filestream.c
+++ b/fs/xfs/xfs_filestream.c
@@ -350,9 +350,10 @@ _xfs_filestream_update_ag(
/* xfs_fstrm_free_func(): callback for freeing cached stream items. */
void
xfs_fstrm_free_func(
-... |
8742bc92c36324ac4bac739ab413acc6630a875d | Analyze and fix the following issue in the Linux kernel code: [ARM] 4569/1: ep93xx_gpio_irq_type(): fix spurious enumeration offset for FGPIO handling | Problem Details:
The EP93XX_GPIO_LINE_F() macro is supposed to be called with a line
number between 0 and 7, but the current code causes it to get called
with an spuriously offset number range {16..23}.
Signed-off-by: Herbert Valerio Riedel <hvr@gnu.org>
Signed-off-by: Lennert Buytenhek <kernel@wantstofly.org>
Signed-... | ```diff
diff --git a/arch/arm/mach-ep93xx/core.c b/arch/arm/mach-ep93xx/core.c
index 851cc7158ca3..70b2c7801110 100644
--- a/arch/arm/mach-ep93xx/core.c
+++ b/arch/arm/mach-ep93xx/core.c
@@ -336,7 +336,7 @@ static int ep93xx_gpio_irq_type(unsigned int irq, unsigned int type)
if (line >= 0 && line < 16) {
gpio_line... |
70dea47da12932cc512e09124a836ddd3499ab39 | Analyze and fix the following issue in the Linux kernel code: [POWERPC] 4xx: Implement udbg_getc() for 440 | Problem Details:
Implement udbg_getc() for 440, which fixes xmon input.
Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com>
Acked-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com> | ```diff
diff --git a/arch/powerpc/kernel/udbg_16550.c b/arch/powerpc/kernel/udbg_16550.c
index 7afab5bcd61a..833a3d0bcfa7 100644
--- a/arch/powerpc/kernel/udbg_16550.c
+++ b/arch/powerpc/kernel/udbg_16550.c
@@ -206,11 +206,22 @@ static void udbg_44x_as1_putc(char c)
}
}
+static int udbg_44x_as1_getc(void)
+{
+ if ... |
31e879309474d1666d645b96de99d0b682fa055f | Analyze and fix the following issue in the Linux kernel code: SELinux: fix array out of bounds when mounting with selinux options | Problem Details:
Given an illegal selinux option it was possible for match_token to work in
random memory at the end of the match_table_t array.
Note that privilege is required to perform a context mount, so this issue is
effectively limited to root only.
Signed-off-by: Eric Paris <eparis@redhat.com>
Acked-by: Stephe... | ```diff
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c
index 36946629b6ca..0753b20e23fe 100644
--- a/security/selinux/hooks.c
+++ b/security/selinux/hooks.c
@@ -316,6 +316,7 @@ static inline int inode_doinit(struct inode *inode)
}
enum {
+ Opt_error = -1,
Opt_context = 1,
Opt_fscontext = 2,
... |
9c95e7319ba98585ebb6d304eca2d56f401ed70c | Analyze and fix the following issue in the Linux kernel code: sched: fix invalid sched_class use | Problem Details:
When using rt_mutex, a NULL pointer dereference is occurred at
enqueue_task_rt. Here is a scenario;
1) there are two threads, the thread A is fair_sched_class and
thread B is rt_sched_class.
2) Thread A is boosted up to rt_sched_class, because the thread A
has a rt_mutex lock and the thread B is ... | ```diff
diff --git a/kernel/sched.c b/kernel/sched.c
index 63e0971c8fbb..6107a0cd6325 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -1682,6 +1682,11 @@ void fastcall wake_up_new_task(struct task_struct *p, unsigned long clone_flags)
p->prio = effective_prio(p);
+ if (rt_prio(p->prio))
+ p->sched_class = &r... |
d78ae2dcc2acebb9a1048278f47f762c069db75c | Analyze and fix the following issue in the Linux kernel code: r8169: workaround against ignored TxPoll writes (8168) | Problem Details:
The 8168 ignores the requests to fetch the Tx descriptors when
the relevant TxPoll bit is already set. It easily kills the
performances of the 8168. David Gundersen has noticed that it
is enough to wait for the completion of the DMA transfer (NPQ
bit is cleared) before writing the TxPoll register again... | ```diff
diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c
index d9bb51bb4b9d..c921ec32c232 100644
--- a/drivers/net/r8169.c
+++ b/drivers/net/r8169.c
@@ -2570,6 +2570,15 @@ static void rtl8169_tx_interrupt(struct net_device *dev,
(TX_BUFFS_AVAIL(tp) >= MAX_SKB_FRAGS)) {
netif_wake_queue(dev);
}
+ /*... |
68835999435e01311ab57f5556169ad2966b6828 | Analyze and fix the following issue in the Linux kernel code: [MIPS] DEC: Initialise ioasic_ssr_lock | Problem Details:
Fix the definition of the ioasic_ssr_lock spinlock to include a proper
initialisation.
Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/arch/mips/dec/setup.c b/arch/mips/dec/setup.c
index b8a5e75ba0ab..3e634f2f5443 100644
--- a/arch/mips/dec/setup.c
+++ b/arch/mips/dec/setup.c
@@ -55,7 +55,7 @@ EXPORT_SYMBOL(dec_kn_slot_size);
int dec_tc_bus;
-spinlock_t ioasic_ssr_lock;
+DEFINE_SPINLOCK(ioasic_ssr_lock);
volatile u32 *ioas... |
4f01a757e75f2a3cab2bab89c4176498963946b9 | Analyze and fix the following issue in the Linux kernel code: Driver core: fix deprectated sysfs structure for nested class devices | Problem Details:
Nested class devices used to have 'device' symlink point to a real
(physical) device instead of a parent class device. When converting
subsystems to struct device we need to keep doing what class devices did if
CONFIG_SYSFS_DEPRECATED is Y, otherwise parts of udev break.
Signed-off-by: Dmitry Torokho... | ```diff
diff --git a/drivers/base/core.c b/drivers/base/core.c
index e6738bcbe5a9..6de33d7a29ba 100644
--- a/drivers/base/core.c
+++ b/drivers/base/core.c
@@ -679,14 +679,26 @@ static int device_add_class_symlinks(struct device *dev)
goto out_subsys;
}
if (dev->parent) {
- error = sysfs_create_link(&dev->kobj,... |
508a92741a105e2e3d466cd727fb73154ebf08de | Analyze and fix the following issue in the Linux kernel code: uml: fix irqstack crash | Problem Details:
This patch fixes a crash caused by an interrupt coming in when an IRQ stack
is being torn down. When this happens, handle_signal will loop, setting up
the IRQ stack again because the tearing down had finished, and handling
whatever signals had come in.
However, to_irq_stack returns a mask of pending ... | ```diff
diff --git a/arch/um/include/kern_util.h b/arch/um/include/kern_util.h
index 8d7f7c1cb9c6..6c2be26f1d7d 100644
--- a/arch/um/include/kern_util.h
+++ b/arch/um/include/kern_util.h
@@ -117,7 +117,7 @@ extern void sigio_handler(int sig, union uml_pt_regs *regs);
extern void copy_sc(union uml_pt_regs *regs, void... |
480eccf9ae1073b87bb4fe118971fbf134a5bc61 | Analyze and fix the following issue in the Linux kernel code: Fix NUMA Memory Policy Reference Counting | Problem Details:
This patch proposes fixes to the reference counting of memory policy in the
page allocation paths and in show_numa_map(). Extracted from my "Memory
Policy Cleanups and Enhancements" series as stand-alone.
Shared policy lookup [shmem] has always added a reference to the policy,
but this was never unre... | ```diff
diff --git a/include/linux/mempolicy.h b/include/linux/mempolicy.h
index 5bdd656e88cf..a020eb2d4e2a 100644
--- a/include/linux/mempolicy.h
+++ b/include/linux/mempolicy.h
@@ -159,7 +159,7 @@ extern void mpol_fix_fork_child_flag(struct task_struct *p);
extern struct mempolicy default_policy;
extern struct zo... |
28f300d23674fa01ae747c66ce861d4ee6aebe8c | Analyze and fix the following issue in the Linux kernel code: Fix user namespace exiting OOPs | Problem Details:
It turned out, that the user namespace is released during the do_exit() in
exit_task_namespaces(), but the struct user_struct is released only during the
put_task_struct(), i.e. MUCH later.
On debug kernels with poisoned slabs this will cause the oops in
uid_hash_remove() because the head of the chai... | ```diff
diff --git a/include/linux/sched.h b/include/linux/sched.h
index 6239bc2c2baa..5445eaec6908 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -1472,6 +1472,7 @@ static inline struct user_struct *get_uid(struct user_struct *u)
}
extern void free_uid(struct user_struct *);
extern void switch_ui... |
ef2b02d3e617cb0400eedf2668f86215e1b0e6af | Analyze and fix the following issue in the Linux kernel code: ext34: ensure do_split leaves enough free space in both blocks | Problem Details:
The do_split() function for htree dir blocks is intended to split a leaf
block to make room for a new entry. It sorts the entries in the original
block by hash value, then moves the last half of the entries to the new
block - without accounting for how much space this actually moves. (IOW,
it moves h... | ```diff
diff --git a/fs/ext3/namei.c b/fs/ext3/namei.c
index 9d4a89820e1e..c1fa1908dba0 100644
--- a/fs/ext3/namei.c
+++ b/fs/ext3/namei.c
@@ -140,7 +140,8 @@ struct dx_frame
struct dx_map_entry
{
u32 hash;
- u32 offs;
+ u16 offs;
+ u16 size;
};
#ifdef CONFIG_EXT3_INDEX
@@ -697,6 +698,10 @@ errout:
* Director... |
49af7ee181f4f516ac99eba85d3f70ed42cabe76 | Analyze and fix the following issue in the Linux kernel code: nfs: fix oops re sysctls and V4 support | Problem Details:
NFS unregisters sysctls only if V4 support is compiled in. However, sysctl
table is not V4 specific, so unregister it always.
Steps to reproduce:
[build nfs.ko with CONFIG_NFS_V4=n]
modrobe nfs
rmmod nfs
ls /proc/sys
Unable to handle kernel paging request at ffffffff880661c0 RIP:
[<ffffffff802... | ```diff
diff --git a/fs/nfs/super.c b/fs/nfs/super.c
index 8ed593766f16..b878528b64c1 100644
--- a/fs/nfs/super.c
+++ b/fs/nfs/super.c
@@ -345,8 +345,8 @@ void __exit unregister_nfs_fs(void)
unregister_shrinker(&acl_shrinker);
#ifdef CONFIG_NFS_V4
unregister_filesystem(&nfs4_fs_type);
- nfs_unregister_sysctl();
#... |
3d82abae9523c33d4a16fdfdfd2bdde316d7b56a | Analyze and fix the following issue in the Linux kernel code: dir_index: error out instead of BUG on corrupt dx dirs | Problem Details:
Convert asserts (BUGs) in dx_probe from bad on-disk data to recoverable
errors with helpful warnings. With help catching other asserts from Duane
Griffin <duaneg@dghda.com>
Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Acked-by: Duane Griffin <duaneg@dghda.com>
Acked-by: Theodore Ts'o <tytso@mit.e... | ```diff
diff --git a/fs/ext3/namei.c b/fs/ext3/namei.c
index 1586807b8177..9d4a89820e1e 100644
--- a/fs/ext3/namei.c
+++ b/fs/ext3/namei.c
@@ -379,13 +379,28 @@ dx_probe(struct dentry *dentry, struct inode *dir,
entries = (struct dx_entry *) (((char *)&root->info) +
root->info.info_length);
- assert(dx_... |
e67aa27a6179c287983c6c525beb5320f5cd1672 | Analyze and fix the following issue in the Linux kernel code: intel-agp: Fix i830 mask variable that changed with G33 support | Problem Details:
The mask on i830 should be 0x70 always, later chips 0xF0 should be okay.
Signed-off-by: Dave Airlie <airlied@linux.ie>
Acked-by: Zhenyu Wang <zhenyu.z.wang@intel.com>
Cc: Michael Haas <laga@laga.ath.cx>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@li... | ```diff
diff --git a/drivers/char/agp/agp.h b/drivers/char/agp/agp.h
index 35ab1a9f8e8b..8955e7ff759a 100644
--- a/drivers/char/agp/agp.h
+++ b/drivers/char/agp/agp.h
@@ -176,7 +176,7 @@ struct agp_bridge_data {
#define I830_GMCH_MEM_MASK 0x1
#define I830_GMCH_MEM_64M 0x1
#define I830_GMCH_MEM_128M 0
-#define I83... |
8c8bd037e5bd7bbc3c82b74cbed4da1ddc3fe8de | Analyze and fix the following issue in the Linux kernel code: intelfb: Fix bug in DPLL disable | Problem Details:
Reported in Kernel Bugzilla 9006
Fix an obvious bug in DPLL disable.
Signed-off-by: Antonino Daplas <adaplas@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> | ```diff
diff --git a/drivers/video/intelfb/intelfbhw.c b/drivers/video/intelfb/intelfbhw.c
index b21d0dec9283..6a47682d8614 100644
--- a/drivers/video/intelfb/intelfbhw.c
+++ b/drivers/video/intelfb/intelfbhw.c
@@ -1352,7 +1352,7 @@ intelfbhw_program_mode(struct intelfb_info *dinfo,
/* turn off PLL */
tmp = INREG... |
248bdd5efca5a113cbf443a993c69e53d370236b | Analyze and fix the following issue in the Linux kernel code: pci: fix unterminated pci_device_id lists | Problem Details:
Fix a couple drivers that do not correctly terminate their pci_device_id
lists. This results in garbage being spewed into modules.pcimap when the
module happens to not have 28 NULL bytes following the table, and/or the
last PCI ID is actually truncated from the table when calculating the
modules.alias... | ```diff
diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c
index 9b07f7851061..dd441ff4af56 100644
--- a/drivers/char/ipmi/ipmi_si_intf.c
+++ b/drivers/char/ipmi/ipmi_si_intf.c
@@ -2215,7 +2215,8 @@ static int ipmi_pci_resume(struct pci_dev *pdev)
static struct pci_device_id ipmi_pci_de... |
2e3e31c05798786c131bf257f64848d4a9a894ab | Analyze and fix the following issue in the Linux kernel code: rtc-ds1742.c should use resource_size_t for base address | Problem Details:
Currently the rtc driver, rtc-ds1742.c uses an unsigned long to store the
base mmio address of the NVRAM/RTC. This breaks on systems like PowerPC
440, which is a 32-bit core with 36-bit physical addresses: IO on the
system, including the RTC, is typically above the 4GB point, and cannot fit
into an un... | ```diff
diff --git a/drivers/rtc/rtc-ds1742.c b/drivers/rtc/rtc-ds1742.c
index b2e5481ba3b6..67291b0f8283 100644
--- a/drivers/rtc/rtc-ds1742.c
+++ b/drivers/rtc/rtc-ds1742.c
@@ -55,7 +55,7 @@ struct rtc_plat_data {
void __iomem *ioaddr_rtc;
size_t size_nvram;
size_t size;
- unsigned long baseaddr;
+ resource_siz... |
efc63c4fb0f95865907472d1c6bc0cfea9ee156b | Analyze and fix the following issue in the Linux kernel code: Fix UTS corruption during clone(CLONE_NEWUTS) | Problem Details:
struct utsname is copied from master one without any exclusion.
Here is sample output from one proggie doing
sethostname("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
sethostname("bbbbbbbbbbbbbbbbbbbbbbbbbbbbbb");
and another
clone(,, CLONE_NEWUTS, ...)
uname()
hostname = 'aaaaaaaaaaaaaaaaaaaaaaaaabbbbb... | ```diff
diff --git a/kernel/utsname.c b/kernel/utsname.c
index 9d8180a0f0d8..816d7b24fa03 100644
--- a/kernel/utsname.c
+++ b/kernel/utsname.c
@@ -28,7 +28,9 @@ static struct uts_namespace *clone_uts_ns(struct uts_namespace *old_ns)
if (!ns)
return ERR_PTR(-ENOMEM);
+ down_read(&uts_sem);
memcpy(&ns->name, &ol... |
019ad4a0a60b09022945273848b5a686e39a78aa | Analyze and fix the following issue in the Linux kernel code: Fix failure to resume from initrds | Problem Details:
Commit 831441862956fffa17b9801db37e6ea1650b0f69 (Freezer: make kernel
threads nonfreezable by default) breaks freezing when attempting to resume
from an initrd, because the init (which is freezeable) spins while waiting
for another thread to run /linuxrc, but doesn't check whether it has been
told to e... | ```diff
diff --git a/init/do_mounts_initrd.c b/init/do_mounts_initrd.c
index a6b4c0c08e13..fd4fc12d2624 100644
--- a/init/do_mounts_initrd.c
+++ b/init/do_mounts_initrd.c
@@ -57,8 +57,10 @@ static void __init handle_initrd(void)
pid = kernel_thread(do_linuxrc, "/linuxrc", SIGCHLD);
if (pid > 0)
- while (pid != s... |
3558c9b3232b5f0fd9f32043a191eca20fca64c6 | Analyze and fix the following issue in the Linux kernel code: Fix "Fix DAC960 driver on machines which don't support 64-bit DMA" | Problem Details:
sparc32:
drivers/block/DAC960.c: In function 'DAC960_V1_EnableMemoryMailboxInterface':
drivers/block/DAC960.c:1168: error: 'DMA_32BIT_MASK' undeclared (first use in this function)
drivers/block/DAC960.c:1168: error: (Each undeclared identifier is reported only
Cc: <dac@conglom-o.org>
Cc: <stable@kern... | ```diff
diff --git a/drivers/block/DAC960.c b/drivers/block/DAC960.c
index 504a95d888b2..84d6aa500e26 100644
--- a/drivers/block/DAC960.c
+++ b/drivers/block/DAC960.c
@@ -31,6 +31,7 @@
#include <linux/genhd.h>
#include <linux/hdreg.h>
#include <linux/blkpg.h>
+#include <linux/dma-mapping.h>
#include <linux/interrup... |
c27da339698145a9383e052c1070a950d30da478 | Analyze and fix the following issue in the Linux kernel code: [POWERPC] Fix timekeeping on PowerPC 601 | Problem Details:
Recent changes to the timekeeping code broke support for the PowerPC 601
processor which doesn't have the usual timebase facility but a slightly
different thing called (yuck) the RTC.
This fixes it, boot tested on an old 601 based PowerMac 7200.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.cras... | ```diff
diff --git a/arch/powerpc/kernel/time.c b/arch/powerpc/kernel/time.c
index 727a6699f2f4..c627cf86d1e3 100644
--- a/arch/powerpc/kernel/time.c
+++ b/arch/powerpc/kernel/time.c
@@ -239,7 +239,7 @@ static void snapshot_tb_and_purr(void *data)
struct cpu_purr_data *p = &__get_cpu_var(cpu_purr_data);
local_irq... |
7b5acbaac3f94ab810a977c0ec4e5fcabbf51bed | Analyze and fix the following issue in the Linux kernel code: [POWERPC] Don't expose clock vDSO functions when CPU has no timebase | Problem Details:
We forgot to remove the clock_gettime, clock_getres and get_tbfreq vDSO
calls on CPUs that have no timebase such as 601 or 403 (old CPUs that have
different mechanisms and for which the vDSO code will not work properly).
This fixes it.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
S... | ```diff
diff --git a/arch/powerpc/kernel/vdso.c b/arch/powerpc/kernel/vdso.c
index cef01e4e8989..213fa31ac537 100644
--- a/arch/powerpc/kernel/vdso.c
+++ b/arch/powerpc/kernel/vdso.c
@@ -98,6 +98,18 @@ static struct vdso_patch_def vdso_patches[] = {
CPU_FTR_USE_TB, 0,
"__kernel_gettimeofday", NULL
},
+ {
+ CPU... |
c0e7b4aa1c09ea992808ea8c079141bc8dd0f5bc | Analyze and fix the following issue in the Linux kernel code: [POWERPC] spusched: Fix null pointer dereference in find_victim | Problem Details:
find_victim can dereference a NULL pointer when iterating over the list
of victim spus because list_mutex only guarantees spu->ct to be stable,
but of course not to be non-NULL.
Also fix find_victim to not call spu_unbind_context without list_mutex
because that violates the above guarantee.
Signed-of... | ```diff
diff --git a/arch/powerpc/platforms/cell/spufs/sched.c b/arch/powerpc/platforms/cell/spufs/sched.c
index c784edd40ea7..5bebe7fbe056 100644
--- a/arch/powerpc/platforms/cell/spufs/sched.c
+++ b/arch/powerpc/platforms/cell/spufs/sched.c
@@ -579,7 +579,7 @@ static struct spu *find_victim(struct spu_context *ctx)
... |
7b2c3c5b1d6dd77d7bb5a7d57ab7280e051c59bc | Analyze and fix the following issue in the Linux kernel code: [POWERPC] Fix section mismatch in PCI code | Problem Details:
Create a helper function (alloc_maybe_bootmem) that is marked __init_refok
to limit the chances of mistakenly referring to other __init routines.
WARNING: vmlinux.o(.text+0x2a9c4): Section mismatch: reference to .init.text:.__alloc_bootmem (between '.update_dn_pci_info' and '.pci_dn_reconfig_notifier'... | ```diff
diff --git a/arch/powerpc/kernel/pci_dn.c b/arch/powerpc/kernel/pci_dn.c
index d7d36df9c053..b4839038613d 100644
--- a/arch/powerpc/kernel/pci_dn.c
+++ b/arch/powerpc/kernel/pci_dn.c
@@ -23,8 +23,6 @@
#include <linux/pci.h>
#include <linux/string.h>
#include <linux/init.h>
-#include <linux/slab.h>
-#include ... |
f9b7bbe7a803c6f10e7b3a354c5d97f632060320 | Analyze and fix the following issue in the Linux kernel code: [POWERPC] spufs: Remove ctx_info and ctx_info_list | Problem Details:
Remove the ctx_info struct entirely, and also the ctx_info_list. This
fixes a race where two processes can clobber each other's ctx_info structs.
Instead of using the list, we just repeat the search through the file
descriptor table.
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Signed-of... | ```diff
diff --git a/arch/powerpc/platforms/cell/spufs/coredump.c b/arch/powerpc/platforms/cell/spufs/coredump.c
index 99f8e0b00897..66636693c9d6 100644
--- a/arch/powerpc/platforms/cell/spufs/coredump.c
+++ b/arch/powerpc/platforms/cell/spufs/coredump.c
@@ -31,15 +31,6 @@
#include "spufs.h"
-struct spufs_ctx_info... |
c70d4ca52b1390dd2603535600c948cbdb0b9ec9 | Analyze and fix the following issue in the Linux kernel code: [POWERPC] cell: Remove DEBUG for SPU callbacks | Problem Details:
We don't want SPE programs to be able to flood the kernel log by
invoking the SPE callback handler, so don't enable DEBUG for
spu_callbacks.c by default.
Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Signed-off-by: Paul Mackerras <paulus@samba.org> | ```diff
diff --git a/arch/powerpc/platforms/cell/spu_callbacks.c b/arch/powerpc/platforms/cell/spu_callbacks.c
index ab39e223d44d..dceb8b6a9382 100644
--- a/arch/powerpc/platforms/cell/spu_callbacks.c
+++ b/arch/powerpc/platforms/cell/spu_callbacks.c
@@ -2,7 +2,7 @@
* System call callback functions for SPUs
*/
-#... |
05a059f3296c07a7455290dd8188b23ecb380fc7 | Analyze and fix the following issue in the Linux kernel code: [POWERPC] spufs: Fix restore_decr_wrapped() to match CBE Handbook | Problem Details:
Based on an original patch from Masato Noguchi
<Masato.Noguchi@jp.sony.com>.
We're currently not restoring the SPE decrementer as specified by the
CBE handbook. This change fixes our implementation to match, and makes
the function read more like the docs.
Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Si... | ```diff
diff --git a/arch/powerpc/platforms/cell/spufs/switch.c b/arch/powerpc/platforms/cell/spufs/switch.c
index 250661991503..de7e5ee451d2 100644
--- a/arch/powerpc/platforms/cell/spufs/switch.c
+++ b/arch/powerpc/platforms/cell/spufs/switch.c
@@ -1559,15 +1559,15 @@ static inline void restore_decr_wrapped(struct sp... |
36ddbb1380f282b4280c57efdb646dd8647a789f | Analyze and fix the following issue in the Linux kernel code: [POWERPC] spufs: Fix race condition on gang->aff_ref_spu | Problem Details:
Affinity reference point location (gang->aff_ref_spu) is reset
when the whole gang is descheduled. However, the last member of
a gang can be descheduled while we are trying to schedule another
member of the gang. This was leading to a race condition, and
the code was using gang->aff_ref_spu in an unsaf... | ```diff
diff --git a/arch/powerpc/platforms/cell/spufs/sched.c b/arch/powerpc/platforms/cell/spufs/sched.c
index c784edd40ea7..17806e001e50 100644
--- a/arch/powerpc/platforms/cell/spufs/sched.c
+++ b/arch/powerpc/platforms/cell/spufs/sched.c
@@ -230,8 +230,6 @@ static void spu_bind_context(struct spu *spu, struct spu_... |
aa0154290fc05948560ac43afcccf8259e10bcd0 | Analyze and fix the following issue in the Linux kernel code: [POWERPC] Fix pmac_zilog debug arg | Problem Details:
drivers/serial/pmac_zilog.c:1590: warning: format '%d' expects type 'int', but argument 3 has type 'pm_message_t'
Signed-off-by: Olaf Hering <olaf@aepfle.de>
Signed-off-by: Paul Mackerras <paulus@samba.org> | ```diff
diff --git a/drivers/serial/pmac_zilog.c b/drivers/serial/pmac_zilog.c
index 0fa9f6761763..f793ac212672 100644
--- a/drivers/serial/pmac_zilog.c
+++ b/drivers/serial/pmac_zilog.c
@@ -1587,7 +1587,7 @@ static int pmz_suspend(struct macio_dev *mdev, pm_message_t pm_state)
if (pm_state.event == mdev->ofdev.dev.p... |
a21101c46ca5b4320e31408853cdcbf7cb1ce4ed | Analyze and fix the following issue in the Linux kernel code: ACPI: video: _DOS=0 by default to prevent hotkey hang | Problem Details:
In the past, the Linux/ACPI video driver invoked _DOS
(Display Output Switch) with the parameter 1
to tell the BIOS to switch the video output display for us.
But this conflicts with Linux native graphics drivers,
and can cause all sorts of issues, including hanging the system.
http://bugzilla.kernel... | ```diff
diff --git a/drivers/acpi/video.c b/drivers/acpi/video.c
index 3c9bb85a6a93..6cb3e7b12145 100644
--- a/drivers/acpi/video.c
+++ b/drivers/acpi/video.c
@@ -1754,7 +1754,7 @@ static int acpi_video_bus_put_devices(struct acpi_video_bus *video)
static int acpi_video_bus_start_devices(struct acpi_video_bus *video... |
8a66074c379cacc79168681bf7dea37ad278f5d1 | Analyze and fix the following issue in the Linux kernel code: sony-laptop/thinkpad-acpi: fix INPUT=n build | Problem Details:
Build errors if CONFIG_SONY_LAPTOP && !INPUT or
if CONFIG_THINKPAD_ACPI && !INPUT:
LD vmlinux
...
drivers/built-in.o: In function `sony_laptop_remove_input':
sony-laptop.c:(.text+0x768fb): undefined reference to `input_unregister_device'
...
drivers/built-in.o: In function `thinkpad_acpi... | ```diff
diff --git a/drivers/misc/Kconfig b/drivers/misc/Kconfig
index 73e248fb2ff1..7b580c3152de 100644
--- a/drivers/misc/Kconfig
+++ b/drivers/misc/Kconfig
@@ -134,6 +134,7 @@ config SONY_LAPTOP
tristate "Sony Laptop Extras"
depends on X86 && ACPI
select BACKLIGHT_CLASS_DEVICE
+ depends on INPUT
---help---... |
9c5b34806c28195e4d0f2deaa41d8158ca5874e1 | Analyze and fix the following issue in the Linux kernel code: [SUNSAB]: Fix several bugs. | Problem Details:
* don't register irq until ->startup() (and release in ->shutdown()).
That avoids oopsen with the current tree when interrupt comes before we'd
set up the data structures for ttyb.
* handle console=ttyS... even when OBP talks to screen/keyboard
* register irq handler for each port, let kernel/irq/han... | ```diff
diff --git a/drivers/serial/sunsab.c b/drivers/serial/sunsab.c
index bca57bb94939..e348ba684050 100644
--- a/drivers/serial/sunsab.c
+++ b/drivers/serial/sunsab.c
@@ -58,6 +58,7 @@ struct uart_sunsab_port {
unsigned char interrupt_mask1;/* ISR1 masking */
unsigned char pvr_dtr_bit; /* Which PVR bit is ... |
4f6627ac3ba6948a4aebec80edfd6565aec3a40c | Analyze and fix the following issue in the Linux kernel code: [ARM] 4568/1: fix l2x0 cache invalidate handling of unaligned addresses | Problem Details:
The l2x0_inv_range() function doesn't handle unaligned addresses
correctly. It's necessary to clean the cache lines that are at the
start and end of the invalidate range, if the addresses are not aligned,
to prevent corruption of other data sharing the same cache line.
Signed-off-by: Rui Sousa <rui.p.... | ```diff
diff --git a/arch/arm/mm/cache-l2x0.c b/arch/arm/mm/cache-l2x0.c
index b4e9b734e0bd..76b800a95191 100644
--- a/arch/arm/mm/cache-l2x0.c
+++ b/arch/arm/mm/cache-l2x0.c
@@ -57,7 +57,17 @@ static void l2x0_inv_range(unsigned long start, unsigned long end)
{
unsigned long addr;
- start &= ~(CACHE_LINE_SIZE - 1... |
7062cdc5edb3ba4b2eb906684cd19e103de1f920 | Analyze and fix the following issue in the Linux kernel code: ide: ST320413A has the same problem as ST340823A | Problem Details:
ST320413A has the same problem as ST340823A. Please see
https://bugs.launchpad.net/ubuntu/+source/linux-source-2.6.15/+bug/26119
From: "Jorge Juan Chico" <jjchico@gmail.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | ```diff
diff --git a/drivers/ide/ide-disk.c b/drivers/ide/ide-disk.c
index eba1adbc1b6a..4754769eda97 100644
--- a/drivers/ide/ide-disk.c
+++ b/drivers/ide/ide-disk.c
@@ -487,6 +487,7 @@ static inline int idedisk_supports_lba48(const struct hd_driveid *id)
*/
static const struct drive_list_entry hpa_list[] = {
{ "... |
ff80f1370f2eff7dd7a828cf2416bf7be697247e | Analyze and fix the following issue in the Linux kernel code: ACPI: thinkpad-acpi: revert new 2.6.23 CONFIG_THINKPAD_ACPI_INPUT_ENABLED option | Problem Details:
Revert new 2.6.23 CONFIG_THINKPAD_ACPI_INPUT_ENABLED Kconfig option because
it would create a legacy we don't want to support.
CONFIG_THINKPAD_ACPI_INPUT_ENABLED was added to try to fix an issue that is
now moot with the addition of the netlink ACPI event report interface to
the ACPI core.
Now that A... | ```diff
diff --git a/Documentation/thinkpad-acpi.txt b/Documentation/thinkpad-acpi.txt
index eb2f5986e1eb..ca89711f1584 100644
--- a/Documentation/thinkpad-acpi.txt
+++ b/Documentation/thinkpad-acpi.txt
@@ -161,20 +161,22 @@ system. Enabling the hotkey functionality of thinkpad-acpi signals the
firmware that such a d... |
fa890d586cc127ce72597ba0a909bfecf784e10c | Analyze and fix the following issue in the Linux kernel code: Fix non-ISA link error in drivers/scsi/advansys.c | Problem Details:
When CONFIG_ISA is disabled, the isa_driver support will not be compiled
in. Define stubs so that we don't get link-time errors.
Signed-off-by: Matthew Wilcox <matthew@wil.cx>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> | ```diff
diff --git a/include/linux/isa.h b/include/linux/isa.h
index 1b855335cb11..b0270e3814c8 100644
--- a/include/linux/isa.h
+++ b/include/linux/isa.h
@@ -22,7 +22,18 @@ struct isa_driver {
#define to_isa_driver(x) container_of((x), struct isa_driver, driver)
+#ifdef CONFIG_ISA
int isa_register_driver(struct ... |
d9f30ec0b0d129b9cbf2b041a6a3159aa24592f6 | Analyze and fix the following issue in the Linux kernel code: [VLAN]: Fix net_device leak. | Problem Details:
In "[VLAN]: Move device registation to seperate function" (commit
e89fe42cd03c8fd3686df82d8390a235717a66de), a pile of code got moved
to register_vlan_dev(), including grabbing a reference to underlying
device. However, original dev_hold() had been left behind, so we
leak a reference to net_device now... | ```diff
diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c
index 1583c5ef963f..2a546919d6fb 100644
--- a/net/8021q/vlan.c
+++ b/net/8021q/vlan.c
@@ -562,8 +562,6 @@ static int register_vlan_device(struct net_device *real_dev,
if (err < 0)
goto out_free_newdev;
- /* Account for reference in struct vlan_dev_info */
... |
2a38b775b77f99308a4e571c13d908df78ac5e57 | Analyze and fix the following issue in the Linux kernel code: [PPP] generic: Fix receive path data clobbering & non-linear handling | Problem Details:
This patch adds missing pskb_may_pull calls to deal with non-linear
packets that may arrive from pppoe or pppol2tp.
It also copies cloned packets before writing over them.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/drivers/net/ppp_generic.c b/drivers/net/ppp_generic.c
index 7e21342becb2..4b49d0e8c7eb 100644
--- a/drivers/net/ppp_generic.c
+++ b/drivers/net/ppp_generic.c
@@ -1525,7 +1525,7 @@ ppp_input_error(struct ppp_channel *chan, int code)
static void
ppp_receive_frame(struct ppp *ppp, struct sk_buff *sk... |
db7bf6d97c6956b7eb0f22131cb5c37bd41f33c0 | Analyze and fix the following issue in the Linux kernel code: [PPP] pppoe: Fix data clobbering in __pppoe_xmit and return value | Problem Details:
The function __pppoe_xmit modifies the skb data and therefore it needs
to copy and skb data if it's cloned.
In fact, it currently allocates a new skb so that it can return 0 in
case of error without freeing the original skb. This is totally wrong
because returning zero is meant to indicate congestion... | ```diff
diff --git a/drivers/net/pppoe.c b/drivers/net/pppoe.c
index 5ac3eff6a2a6..8818253102f2 100644
--- a/drivers/net/pppoe.c
+++ b/drivers/net/pppoe.c
@@ -850,9 +850,7 @@ static int __pppoe_xmit(struct sock *sk, struct sk_buff *skb)
struct net_device *dev = po->pppoe_dev;
struct pppoe_hdr hdr;
struct pppoe_hd... |
31bac44468257986484703cc09da8a9dcae88a36 | Analyze and fix the following issue in the Linux kernel code: [PPP] pppoe: Fix skb_unshare_check call position | Problem Details:
The skb_unshare_check call needs to be made before pskb_may_pull,
not after.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/drivers/net/pppoe.c b/drivers/net/pppoe.c
index 68631a5721ac..5ac3eff6a2a6 100644
--- a/drivers/net/pppoe.c
+++ b/drivers/net/pppoe.c
@@ -385,12 +385,12 @@ static int pppoe_rcv(struct sk_buff *skb,
struct pppoe_hdr *ph;
struct pppox_sock *po;
- if (!pskb_may_pull(skb, sizeof(struct pppoe_hdr)... |
5a07cdf86c1485b570789fb660c8ada7c2635b23 | Analyze and fix the following issue in the Linux kernel code: [CIFS] fix small memory leak in an error path in new posix mkdir | Problem Details:
There is a small memory leak in fs/cifs/inode.c::cifs_mkdir().
Storage for 'pInfo' is allocated with kzalloc(), but if the call
to CIFSPOSIXCreate(...) happens to return 0 and pInfo->Type == -1,
then we'll jump to the 'mkdir_get_info' label without freeing the
storage allocated for 'pInfo'.
This patch ... | ```diff
diff --git a/fs/cifs/inode.c b/fs/cifs/inode.c
index e800c0ef54f6..9dffa93d6bdd 100644
--- a/fs/cifs/inode.c
+++ b/fs/cifs/inode.c
@@ -930,8 +930,10 @@ int cifs_mkdir(struct inode *inode, struct dentry *direntry, int mode)
d_drop(direntry);
} else {
int obj_type;
- if (pInfo->Type == -1) /* no retu... |
ce5d0b47f13f83dfb9fbb8ac91adad7120747aaf | Analyze and fix the following issue in the Linux kernel code: [PKTGEN]: srcmac fix | Problem Details:
From: Adit Ranadive <adit.262@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/net/core/pktgen.c b/net/core/pktgen.c
index 36fdea71d742..803d0c8826af 100644
--- a/net/core/pktgen.c
+++ b/net/core/pktgen.c
@@ -111,6 +111,9 @@
*
* 802.1Q/Q-in-Q support by Francesco Fondelli (FF) <francesco.fondelli@gmail.com>
*
+ * Fixed src_mac command to set source mac of packet to valu... |
6ae5f983cf8de769214d2d9e8a783c881eccd4cd | Analyze and fix the following issue in the Linux kernel code: [IPV6]: Fix source address selection. | Problem Details:
The commit 95c385 broke proper source address selection for cases in which
there is a address which is makred 'deprecated'. The commit mistakenly
changed ifa->flags to ifa_result->flags (probably copy/paste error from a
few lines above) in the 'Rule 3' address selection code.
The patch restores the... | ```diff
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index 91ef3be5abad..45b4c82148a0 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -1021,7 +1021,7 @@ int ipv6_dev_get_saddr(struct net_device *daddr_dev,
hiscore.rule++;
}
if (ipv6_saddr_preferred(score.addr_type) ||
- (((ifa_... |
301feb652441a7168b59256fc44918075dcab0d5 | Analyze and fix the following issue in the Linux kernel code: [SPARC64]: Fix lockdep, particularly on SMP. | Problem Details:
As noted by Al Viro, when we try to call prom_set_trap_table()
in the SMP trampoline code we try to take the PROM call spinlock
which doesn't work because the current thread pointer isn't
valid yet and lockdep depends upon that being correct.
Furthermore, we cannot set the current thread pointer regis... | ```diff
diff --git a/arch/sparc64/kernel/head.S b/arch/sparc64/kernel/head.S
index 63144ad476f6..c4147ad8677b 100644
--- a/arch/sparc64/kernel/head.S
+++ b/arch/sparc64/kernel/head.S
@@ -98,7 +98,7 @@ sparc64_boot:
.globl prom_boot_mapped_pc, prom_boot_mapping_mode
.globl prom_boot_mapping_phys_high, prom_boot_mapp... |
6a669ee8a790487b7ec1edda762d39615a78264b | Analyze and fix the following issue in the Linux kernel code: timekeeping: Prevent time going backwards on resume | Problem Details:
Timekeeping resume adjusts xtime by adding the slept time in seconds and
resets the reference value of the clock source (clock->cycle_last).
clock->cycle last is used to calculate the delta between the last xtime
update and the readout of the clock source in __get_nsec_offset(). xtime
plus the offset i... | ```diff
diff --git a/kernel/time/timekeeping.c b/kernel/time/timekeeping.c
index f682091fa890..4ad79f6bdec6 100644
--- a/kernel/time/timekeeping.c
+++ b/kernel/time/timekeeping.c
@@ -217,6 +217,7 @@ static void change_clocksource(void)
}
#else
static inline void change_clocksource(void) { }
+static inline s64 __get_... |
fadacb1b80e35e0b36a90d43e21ef91eec4b889b | Analyze and fix the following issue in the Linux kernel code: drivers/net/pcmcia/3c589_cs: fix port configuration switcheroo | Problem Details:
10base2 and 10baseT were accidentally switched.
Noticed by Andreas HÃŒbner, forwarded by Alan Cox.
Signed-off-by: Jeff Garzik <jeff@garzik.org> | ```diff
diff --git a/drivers/net/pcmcia/3c589_cs.c b/drivers/net/pcmcia/3c589_cs.c
index 503f2685fb73..c06cae3f0b56 100644
--- a/drivers/net/pcmcia/3c589_cs.c
+++ b/drivers/net/pcmcia/3c589_cs.c
@@ -116,7 +116,7 @@ struct el3_private {
spinlock_t lock;
};
-static const char *if_names[] = { "auto", "10baseT", "... |
62270336e8fdfbea36cb455c27744c23780dbf07 | Analyze and fix the following issue in the Linux kernel code: ucc_geth: fix compilation | Problem Details:
Currently qe_bd_t is used in the macro call -- dma_unmap_single,
which is a no-op on PPC32, thus error is hidden today. Starting
with 2.6.24, macro will be replaced by the empty static function,
and erroneous use of qe_bd_t will trigger compilation error.
Signed-off-by: Anton Vorontsov <avorontsov@ru.... | ```diff
diff --git a/drivers/net/ucc_geth.c b/drivers/net/ucc_geth.c
index 12e01b24105a..9a38dfe45f8f 100644
--- a/drivers/net/ucc_geth.c
+++ b/drivers/net/ucc_geth.c
@@ -2148,7 +2148,7 @@ static void ucc_geth_memclean(struct ucc_geth_private *ugeth)
for (j = 0; j < ugeth->ug_info->bdRingLenTx[i]; j++) {
if (uge... |
e7e381f639657b2e681ff6fb31e131db360550ac | Analyze and fix the following issue in the Linux kernel code: mv643xx_eth: Fix tx_bytes stats calculation | Problem Details:
Reported by Corey Minyard <cminyard@mvista.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org> | ```diff
diff --git a/drivers/net/mv643xx_eth.c b/drivers/net/mv643xx_eth.c
index 1799eee88db7..6a117e9968cb 100644
--- a/drivers/net/mv643xx_eth.c
+++ b/drivers/net/mv643xx_eth.c
@@ -1222,7 +1222,7 @@ static int mv643xx_eth_start_xmit(struct sk_buff *skb, struct net_device *dev)
spin_lock_irqsave(&mp->lock, flags);
... |
bb8bd3a52a5dbca8bea31bfc72dacfb384170e69 | Analyze and fix the following issue in the Linux kernel code: sparc64 (and others): fix tty_ioctl.c build | Problem Details:
Add Guards around TIOCSLCKTRMIOS and TIOCGLCKTRMIOS.
Several architectures are still broken. Put temporary-for-2.6.23 ifdef guards
around the offending code.
Signed-off-by: Tony Breeds <tony@bakeyournoodle.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Benjami... | ```diff
diff --git a/drivers/char/tty_ioctl.c b/drivers/char/tty_ioctl.c
index 4a8969cef315..3ee73cf64bd2 100644
--- a/drivers/char/tty_ioctl.c
+++ b/drivers/char/tty_ioctl.c
@@ -795,6 +795,19 @@ int n_tty_ioctl(struct tty_struct * tty, struct file * file,
if (L_ICANON(tty))
retval = inq_canon(tty);
return... |
a23d30698190f05491a6096f027311f94d4d26d5 | Analyze and fix the following issue in the Linux kernel code: [CIFS] missing field in debug output from previous fix | Problem Details:
Signed-off-by: Steve French <sfrench@us.ibm.com> | ```diff
diff --git a/fs/cifs/cifs_debug.c b/fs/cifs/cifs_debug.c
index 0356694b5cd0..56c5d9126f50 100644
--- a/fs/cifs/cifs_debug.c
+++ b/fs/cifs/cifs_debug.c
@@ -213,7 +213,8 @@ cifs_debug_data_read(char *buf, char **beginBuffer, off_t offset,
tcon->treeName, atomic_read(&tcon->useCount));
buf += length;
i... |
88f370a688e765de9755a343702ca04e6817e5f5 | Analyze and fix the following issue in the Linux kernel code: [CIFS] Fix potential NULL pointer usage if kzalloc fails | Problem Details:
Potential problem was noticed by Cyrill Gorcunov
CC: Cyrill Gorcunov <gorcunov@gmail.com>
Signed-off-by: Steve French <sfrench@us.ibm.com> | ```diff
diff --git a/fs/cifs/cifs_debug.c b/fs/cifs/cifs_debug.c
index 1bf8cf522ad6..0356694b5cd0 100644
--- a/fs/cifs/cifs_debug.c
+++ b/fs/cifs/cifs_debug.c
@@ -209,13 +209,15 @@ cifs_debug_data_read(char *buf, char **beginBuffer, off_t offset,
i++;
tcon = list_entry(tmp, struct cifsTconInfo, cifsConnectionList... |
638b250766272fcaaa0f7ed2776f58f4ac701914 | Analyze and fix the following issue in the Linux kernel code: [CIFS] typo in earlier cifs_reconnect fix | Problem Details:
Signed-off-by: Steve French <sfrench@us.ibm.com> | ```diff
diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c
index f58fef5878c3..a83684d8eb5a 100644
--- a/fs/cifs/connect.c
+++ b/fs/cifs/connect.c
@@ -439,7 +439,6 @@ incomplete_rcv:
cFYI(1, ("less than four bytes received (%d bytes)",
length));
pdu_length -= length;
- cifs_reconnect(server);
ms... |
3ef9d943d26dea764f4fecf3767001c90b778b0c | Analyze and fix the following issue in the Linux kernel code: [IPV6]: Fix unbalanced socket reference with MSG_CONFIRM. | Problem Details:
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net> | ```diff
diff --git a/net/ipv6/raw.c b/net/ipv6/raw.c
index e27383d855de..77167afa3455 100644
--- a/net/ipv6/raw.c
+++ b/net/ipv6/raw.c
@@ -882,11 +882,10 @@ back_from_confirm:
ip6_flush_pending_frames(sk);
else if (!(msg->msg_flags & MSG_MORE))
err = rawv6_push_pending_frames(sk, &fl, rp);
+ release_sock(sk... |
e1e992e52faa588667e1378a2573b4b8e3fa6670 | Analyze and fix the following issue in the Linux kernel code: [NET_SCHED] protect action config/dump from irqs | Problem Details:
(with no apologies to C Heston)
On Mon, 2007-10-09 at 21:00 +0800, Herbert Xu wrote:
On Sun, Sep 02, 2007 at 01:11:29PM +0000, Christian Kujau wrote:
> >
> > after upgrading to 2.6.23-rc5 (and applying davem's fix [0]), lockdep
> > was quite noisy when I tried to shape my external (wireless) interface... | ```diff
diff --git a/net/sched/act_api.c b/net/sched/act_api.c
index feef366cad5d..72cdb0fade20 100644
--- a/net/sched/act_api.c
+++ b/net/sched/act_api.c
@@ -68,7 +68,7 @@ static int tcf_dump_walker(struct sk_buff *skb, struct netlink_callback *cb,
int err = 0, index = -1,i = 0, s_i = 0, n_i = 0;
struct rtattr *r ... |
4878809f711981a602cc562eb47994fc81ea0155 | Analyze and fix the following issue in the Linux kernel code: [NET]: Fix two issues wrt. SO_BINDTODEVICE. | Problem Details:
1) Comments suggest that setting optlen to zero will unbind
the socket from whatever device it might be attached to. This
hasn't been the case since at least 2.2.x because the first thing
this function does is return -EINVAL if 'optlen' is less than
sizeof(int).
This check also means t... | ```diff
diff --git a/net/core/sock.c b/net/core/sock.c
index cfed7d42c485..190de61cd648 100644
--- a/net/core/sock.c
+++ b/net/core/sock.c
@@ -362,6 +362,61 @@ struct dst_entry *sk_dst_check(struct sock *sk, u32 cookie)
}
EXPORT_SYMBOL(sk_dst_check);
+static int sock_bindtodevice(struct sock *sk, char __user *optva... |
22d95b1282810f5af599ee292b3fc443aefbdad0 | Analyze and fix the following issue in the Linux kernel code: KVM: MMU: Fix rare oops on guest context switch | Problem Details:
A guest context switch to an uncached cr3 can require allocation of
shadow pages, but we only recycle shadow pages in kvm_mmu_page_fault().
Move shadow page recycling to mmu_topup_memory_caches(), which is called
from both the page fault handler and from guest cr3 reload.
Signed-off-by: Avi Kivity <a... | ```diff
diff --git a/drivers/kvm/kvm.h b/drivers/kvm/kvm.h
index 3ac9cbce3369..336be86c6f5a 100644
--- a/drivers/kvm/kvm.h
+++ b/drivers/kvm/kvm.h
@@ -619,7 +619,7 @@ unsigned long segment_base(u16 selector);
void kvm_mmu_pte_write(struct kvm_vcpu *vcpu, gpa_t gpa,
const u8 *old, const u8 *new, int bytes);
... |
7a1fa065a0264f6b3d3003ba5635289f6583c478 | Analyze and fix the following issue in the Linux kernel code: Correctly close old nfsd/lockd sockets. | Problem Details:
Commit aaf68cfbf2241d24d46583423f6bff5c47e088b3 added a bias
to sk_inuse, so this test for an unused socket now fails. So no
sockets get closed because they are old (they might get closed
if the client closed them).
This bug has existed since 2.6.21-rc1.
Thanks to Wolfgang Walter for finding and rep... | ```diff
diff --git a/net/sunrpc/svcsock.c b/net/sunrpc/svcsock.c
index 12ff5da8160e..1a899924023f 100644
--- a/net/sunrpc/svcsock.c
+++ b/net/sunrpc/svcsock.c
@@ -1592,7 +1592,7 @@ svc_age_temp_sockets(unsigned long closure)
if (!test_and_set_bit(SK_OLD, &svsk->sk_flags))
continue;
- if (atomic_read(&svsk->sk... |
2123a09f3f129f4d56f59026ec63e5990f86db2f | Analyze and fix the following issue in the Linux kernel code: Fix kernel buuild with (CONFIG_COMPAT && ! CONFIG_BLOCK) | Problem Details:
Commit 02a5e0acb3cb85d80d0fe834e366d38a92bbaa22 ("BLOCK: Hide the
contents of linux/bio.h if CONFIG_BLOCK=n") broke the kernel build for
the CONFIG_COMPAT && !CONFIG_BLOCK case:
CC fs/compat_ioctl.o
In file included from include/linux/raid/md_k.h:19,
from include/linux/ra... | ```diff
diff --git a/drivers/md/dm-bio-list.h b/drivers/md/dm-bio-list.h
index 16ee3b018b3a..3f7b827649e3 100644
--- a/drivers/md/dm-bio-list.h
+++ b/drivers/md/dm-bio-list.h
@@ -9,6 +9,8 @@
#include <linux/bio.h>
+#ifdef CONFIG_BLOCK
+
struct bio_list {
struct bio *head;
struct bio *tail;
@@ -106,4 +108,5 @@... |
7d7d6068bee9d8004ea7cc8a2ebda2c99a57caec | Analyze and fix the following issue in the Linux kernel code: Btrfs: Fix cache_block_group to catch holes at the start of the group | Problem Details:
Cache block group was overly complex and missed free blocks at the very start
of the group. This patch simplifies things significantly.
Signed-off-by: Chris Mason <chris.mason@oracle.com> | ```diff
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c
index b074ad1416dd..9151850266b0 100644
--- a/fs/btrfs/extent-tree.c
+++ b/fs/btrfs/extent-tree.c
@@ -39,6 +39,7 @@ static int cache_block_group(struct btrfs_root *root,
u64 i;
u64 last = 0;
u64 hole_size;
+ u64 first_free;
int found = 0;
... |
3f7086978fc0193eff24a77d8b57ac4debc088fa | Analyze and fix the following issue in the Linux kernel code: [PATCH] bcm43xx: Fix cancellation of work queue crashes | Problem Details:
A crash upon booting that is caused by bcm43xx has been reported [1] and
found to be due to a work queue being reinitialized while work on that
queue is still pending. This fix modifies the shutdown of work queues and
prevents periodic work from being requeued during shutdown. With this patch,
no more ... | ```diff
diff --git a/drivers/net/wireless/bcm43xx/bcm43xx_main.c b/drivers/net/wireless/bcm43xx/bcm43xx_main.c
index c5d6753a55ea..dfbd01eaaf34 100644
--- a/drivers/net/wireless/bcm43xx/bcm43xx_main.c
+++ b/drivers/net/wireless/bcm43xx/bcm43xx_main.c
@@ -3183,6 +3183,9 @@ static void bcm43xx_periodic_work_handler(struc... |
48d480b0bde794781fcae9501fb043c1bac0e523 | Analyze and fix the following issue in the Linux kernel code: [MIPS] Malta: Fix off by one bug in interrupt handler. | Problem Details:
Fairly cosmetic as it would only affect VSMP / SMTC kernels that don't
use vectored interrupts.
Found by Beth.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/arch/mips/mips-boards/malta/malta_int.c b/arch/mips/mips-boards/malta/malta_int.c
index 97aeb8c4e601..b73f21823c5e 100644
--- a/arch/mips/mips-boards/malta/malta_int.c
+++ b/arch/mips/mips-boards/malta/malta_int.c
@@ -256,7 +256,7 @@ asmlinkage void plat_irq_dispatch(void)
if (irq == MIPSCPU_IN... |
4d24c8f955b8c9d51c5fe7299c898527e94d39ad | Analyze and fix the following issue in the Linux kernel code: [MIPS] rtlx: Fix build error. | Problem Details:
CC arch/mips/kernel/rtlx.o
cc1: warnings being treated as errors
arch/mips/kernel/rtlx.c:59: warning: 'irq' defined but not used
arch/mips/kernel/rtlx.c:60: warning: 'irq_num' defined but not used
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/arch/mips/kernel/rtlx.c b/arch/mips/kernel/rtlx.c
index 04d8ee787f78..1ba00c15505b 100644
--- a/arch/mips/kernel/rtlx.c
+++ b/arch/mips/kernel/rtlx.c
@@ -56,8 +56,6 @@ static struct chan_waitqueues {
struct mutex mutex;
} channel_wqs[RTLX_CHANNELS];
-static struct irqaction irq;
-static int ir... |
e606c109c485c6f8e27dd6ddcd2c0b58c96fc5c9 | Analyze and fix the following issue in the Linux kernel code: [MIPS] rtlx: fix int vs. long bug. | Problem Details:
CC arch/mips/kernel/rtlx.o
arch/mips/kernel/rtlx.c: In function 'rtlx_init':
arch/mips/kernel/rtlx.c:114: warning: format '%x' expects type 'unsigned int', but argument 3 has type 'long unsigned int'
Signed-off-by: Ralf Baechle <ralf@linux-mips.org> | ```diff
diff --git a/arch/mips/kernel/rtlx.c b/arch/mips/kernel/rtlx.c
index aab89e97abb5..04d8ee787f78 100644
--- a/arch/mips/kernel/rtlx.c
+++ b/arch/mips/kernel/rtlx.c
@@ -111,7 +111,7 @@ static void __used dump_rtlx(void)
static int rtlx_init(struct rtlx_info *rtlxi)
{
if (rtlxi->id != RTLX_ID) {
- printk(KERN... |
e90ff9239e7636a191a8998a70cea220a2c58cdf | Analyze and fix the following issue in the Linux kernel code: V4L/DVB (6220a): fix build error for et61x251 driver | Problem Details:
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> | ```diff
diff --git a/include/media/v4l2-dev.h b/include/media/v4l2-dev.h
index d62847f846c2..17f8f3a2f0a3 100644
--- a/include/media/v4l2-dev.h
+++ b/include/media/v4l2-dev.h
@@ -337,6 +337,9 @@ void *priv;
struct class_device class_dev; /* sysfs */
};
+/* Class-dev to video-device */
+#define to_video_device(cd) ... |
48200baeab95fd39a7f4c4f3536c7142a64ac335 | Analyze and fix the following issue in the Linux kernel code: V4L/DVB (6188): Avoid a NULL pointer dereference during mpeg_open() | Problem Details:
Bug: With a hardware encoder board installed as cx88[1] and a
non-encoder boards installed as cx88[0], an OOPS is generated
during cx8802_get_device() called from mpeg_open().
Signed-off-by: Steven Toth <stoth@hauppauge.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> | ```diff
diff --git a/drivers/media/video/cx88/cx88-mpeg.c b/drivers/media/video/cx88/cx88-mpeg.c
index 317a2a3f9cc1..da7a6b591a67 100644
--- a/drivers/media/video/cx88/cx88-mpeg.c
+++ b/drivers/media/video/cx88/cx88-mpeg.c
@@ -580,7 +580,7 @@ struct cx8802_dev * cx8802_get_device(struct inode *inode)
list_for_each(... |
f5ab272bbff2a37d6d8f84328b6d25d0cdbda605 | Analyze and fix the following issue in the Linux kernel code: V4L/DVB (6148): Fix a warning at saa7191_probe | Problem Details:
saa7191.c: In function 'saa7191_probe':
saa7191.c:596: warning: passing argument 3 of
'saa7191_write_block' discards qualifiers from pointer target type
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org> | ```diff
diff --git a/drivers/media/video/saa7191.c b/drivers/media/video/saa7191.c
index 8615a6081a5d..b4018cce3285 100644
--- a/drivers/media/video/saa7191.c
+++ b/drivers/media/video/saa7191.c
@@ -130,7 +130,7 @@ static int saa7191_write_reg(struct i2c_client *client, u8 reg,
/* the first byte of data must be the ... |
7b9fbc3e30f785412a26819aa4daf0b6c27f6c53 | Analyze and fix the following issue in the Linux kernel code: V4L/DVB (6147): Pwc: Fix a broken debug message | Problem Details:
Commit 85237f202d46d55c1bffe0c5b1aa3ddc0f1dce4d introduced the
following warning (with CONFIG_USB_PWC_DEBUG=y):
drivers/media/video/pwc/pwc-if.c: In function "pwc_video_close":
drivers/media/video/pwc/pwc-if.c:1211: warning: "i" may be used uninitialized in this function
This is true, and can cause a ... | ```diff
diff --git a/drivers/media/video/pwc/pwc-if.c b/drivers/media/video/pwc/pwc-if.c
index 3d81966d8c42..931b274bffca 100644
--- a/drivers/media/video/pwc/pwc-if.c
+++ b/drivers/media/video/pwc/pwc-if.c
@@ -1243,7 +1243,7 @@ static int pwc_video_close(struct inode *inode, struct file *file)
PWC_ERROR("Failed t... |
f5e4feead773cb449212eacfa254a238a953d4d5 | Analyze and fix the following issue in the Linux kernel code: V4L/DVB (6144): Fix mux setup for composite sound on AverTV 307 | Problem Details:
Right now the composite sound input doesn't work on AverTV 307 because of
the wrong mux setup. The composite sound is routed via an external
4channel multiplexer controlled by GPIO, while the code assumes an internal
multiplexer instead.
Presumably this was a copy/paste error, and noone have ever tes... | ```diff
diff --git a/drivers/media/video/saa7134/saa7134-cards.c b/drivers/media/video/saa7134/saa7134-cards.c
index 8ec83bd70094..25ec16810818 100644
--- a/drivers/media/video/saa7134/saa7134-cards.c
+++ b/drivers/media/video/saa7134/saa7134-cards.c
@@ -1537,18 +1537,18 @@ struct saa7134_board saa7134_boards[] = {
... |
5614b02143171a99e0e6eb6c7d1d2f8750d2957f | Analyze and fix the following issue in the Linux kernel code: V4L/DVB (6095): ivtv: fix VIDIOC_G_ENC_INDEX flag handling | Problem Details:
Due to a documentation bug (the type mask is 3 bits long, not 2) the wrong
frame types were filled in: the B and P frame types were swapped.
This bug also hid a second bug: when a capture is stopped a last entry is
written into the pgm index buffer with internal type 0, denoting the end
of the program... | ```diff
diff --git a/Documentation/video4linux/cx2341x/fw-encoder-api.txt b/Documentation/video4linux/cx2341x/fw-encoder-api.txt
index 5dd3109a8b3f..5a27af2ee1c6 100644
--- a/Documentation/video4linux/cx2341x/fw-encoder-api.txt
+++ b/Documentation/video4linux/cx2341x/fw-encoder-api.txt
@@ -407,8 +407,10 @@ Description
... |
6af858b24c0c4e91ce0b40b5dd5fdfc1fe2dda70 | Analyze and fix the following issue in the Linux kernel code: Btrfs: Fix off by one error in dirty_and_release_pages | Problem Details:
Signed-off-by: Chris Mason <chris.mason@oracle.com> | ```diff
diff --git a/fs/btrfs/file.c b/fs/btrfs/file.c
index ca7e5d4474e0..26826a543355 100644
--- a/fs/btrfs/file.c
+++ b/fs/btrfs/file.c
@@ -236,7 +236,7 @@ static int dirty_and_release_pages(struct btrfs_trans_handle *trans,
end_pos - start_pos, p, 0);
BUG_ON(err);
em->start = start_pos;
- em->end = ... |
af6a9aabc106b70ab03d6665c713bca3dd3cb195 | Analyze and fix the following issue in the Linux kernel code: [POWERPC] 52xx: Fix mpc52xx_uart_of_assign to use correct index | Problem Details:
Use idx as index into mpc52xx_uart_nodes instead of i
Signed-off-by: John Rigby <jrigby@freescale.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org> | ```diff
diff --git a/drivers/serial/mpc52xx_uart.c b/drivers/serial/mpc52xx_uart.c
index 35f8b86cc78f..035cca028199 100644
--- a/drivers/serial/mpc52xx_uart.c
+++ b/drivers/serial/mpc52xx_uart.c
@@ -1051,7 +1051,7 @@ mpc52xx_uart_of_assign(struct device_node *np, int idx)
/* If the slot is already occupied, then swap... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.