From 5799af7217b3c092c2393bebe8e7f54f4ef5ba4f Mon Sep 17 00:00:00 2001 From: Alexandre Oliva Date: Wed, 22 Feb 2012 09:01:03 +0000 Subject: 3.2.7-1.fc16 --- freed-ora/current/f16/config-generic | 15 ++- freed-ora/current/f16/kernel.spec | 38 ++++++- .../f16/lis3-improve-handling-of-null-rate.patch | 79 ++++++++++++++ freed-ora/current/f16/nfs-oops-getacl.patch | 96 +++++++++++++++++ freed-ora/current/f16/patch-libre-3.2.6.xz.sign | 7 -- freed-ora/current/f16/patch-libre-3.2.7.xz.sign | 7 ++ .../f16/scsi-fix-sd_revalidate_disk-oops.patch | 116 +++++++++++++++++++++ freed-ora/current/f16/sources | 2 +- 8 files changed, 346 insertions(+), 14 deletions(-) create mode 100644 freed-ora/current/f16/lis3-improve-handling-of-null-rate.patch create mode 100644 freed-ora/current/f16/nfs-oops-getacl.patch delete mode 100644 freed-ora/current/f16/patch-libre-3.2.6.xz.sign create mode 100644 freed-ora/current/f16/patch-libre-3.2.7.xz.sign create mode 100644 freed-ora/current/f16/scsi-fix-sd_revalidate_disk-oops.patch (limited to 'freed-ora') diff --git a/freed-ora/current/f16/config-generic b/freed-ora/current/f16/config-generic index 3b7e800c3..3f46f7160 100644 --- a/freed-ora/current/f16/config-generic +++ b/freed-ora/current/f16/config-generic @@ -4162,7 +4162,20 @@ CONFIG_NE2000=m # CONFIG_SERIAL_8250_HUB6 is not set # CONFIG_SERIAL_8250_EXAR_ST16C554 is not set -# CONFIG_RADIO_ADAPTERS is not set +CONFIG_RADIO_ADAPTERS=y +CONFIG_RADIO_TEA5764=m +CONFIG_RADIO_SAA7706H=m +CONFIG_RADIO_CADET=m +CONFIG_RADIO_RTRACK=m +CONFIG_RADIO_RTRACK2=m +CONFIG_RADIO_AZTECH=m +CONFIG_RADIO_GEMTEK=m +CONFIG_RADIO_SF16FMI=m +CONFIG_RADIO_SF16FMR2=m +CONFIG_RADIO_TERRATEC=m +CONFIG_RADIO_TRUST=m +CONFIG_RADIO_TYPHOON=m +CONFIG_RADIO_ZOLTRIX=m # CONFIG_SND_OPL4_LIB is not set # CONFIG_SND_AD1816A is not set diff --git a/freed-ora/current/f16/kernel.spec b/freed-ora/current/f16/kernel.spec index 8b713319e..fc3d6e42e 100644 --- a/freed-ora/current/f16/kernel.spec +++ b/freed-ora/current/f16/kernel.spec @@ -54,7 +54,7 @@ Summary: The Linux kernel # For non-released -rc kernels, this will be appended after the rcX and # gitX tags, so a 3 here would become part of release "0.rcX.gitX.3" # -%global baserelease 4 +%global baserelease 1 %global fedora_build %{baserelease} # base_sublevel is the kernel version we're starting with and patching @@ -80,7 +80,7 @@ Summary: The Linux kernel %if 0%{?released_kernel} # Do we have a -stable update to apply? -%define stable_update 6 +%define stable_update 7 # Is it a -stable RC? %define stable_rc 0 # Set rpm version accordingly @@ -777,6 +777,8 @@ Patch13003: efi-dont-map-boot-services-on-32bit.patch Patch14000: hibernate-freeze-filesystems.patch +Patch14010: lis3-improve-handling-of-null-rate.patch + Patch20000: utrace.patch # Flattened devicetree support @@ -786,8 +788,10 @@ Patch21001: arm-smsc-support-reading-mac-address-from-device-tree.patch #rhbz 717735 Patch21045: nfs-client-freezer.patch +Patch21046: nfs-oops-getacl.patch + #rhbz 590880 -Patch21046: alps.patch +Patch21050: alps.patch Patch21070: ext4-Support-check-none-nocheck-mount-options.patch Patch21071: ext4-Fix-error-handling-on-inode-bitmap-corruption.patch @@ -828,7 +832,8 @@ Patch21233: jbd2-clear-BH_Delay-and-BH_Unwritten-in-journal_unmap_buf.patch Patch21234: e1000e-Avoid-wrong-check-on-TX-hang.patch #rhbz 754518 -Patch21235: scsi-sd_revalidate_disk-prevent-NULL-ptr-deref.patch +#Patch21235: scsi-sd_revalidate_disk-prevent-NULL-ptr-deref.patch +Patch21235: scsi-fix-sd_revalidate_disk-oops.patch #rhbz 790367 Patch21239: s390x-enable-keys-compat.patch @@ -1539,6 +1544,8 @@ ApplyPatch efi-dont-map-boot-services-on-32bit.patch ApplyPatch hibernate-freeze-filesystems.patch +ApplyPatch lis3-improve-handling-of-null-rate.patch + # utrace. ApplyPatch utrace.patch @@ -1553,6 +1560,8 @@ ApplyPatch hpsa-add-irqf-shared.patch #rhbz 717735 ApplyPatch nfs-client-freezer.patch +ApplyPatch nfs-oops-getacl.patch + #rhbz 590880 ApplyPatch alps.patch @@ -1585,7 +1594,8 @@ ApplyPatch jbd2-clear-BH_Delay-and-BH_Unwritten-in-journal_unmap_buf.patch ApplyPatch e1000e-Avoid-wrong-check-on-TX-hang.patch #rhbz 754518 -ApplyPatch scsi-sd_revalidate_disk-prevent-NULL-ptr-deref.patch +#ApplyPatch scsi-sd_revalidate_disk-prevent-NULL-ptr-deref.patch +ApplyPatch scsi-fix-sd_revalidate_disk-oops.patch #rhbz 790367 ApplyPatch s390x-enable-keys-compat.patch @@ -2395,6 +2405,24 @@ fi # and build. %changelog +* Tue Feb 21 2012 Alexandre Oliva -libre +- Use patch-3.2-libre-3.2.7-libre as patch-libre-3.2.7. + +* Mon Feb 20 2012 Dave Jones 3.2.7-1 +- Do not call drivers when invalidating partitions for -ENOMEDIUM + +* Mon Feb 20 2012 Dave Jones +- Linux 3.2.7 + +* Mon Feb 20 2012 Dave Jones +- NFSv4: Fix an Oops in the NFSv4 getacl code + +* Fri Feb 17 2012 Dave Jones +- improve handling of null rate in LIS3LV02Dx accelerometer driver. (rhbz 785814) + +* Fri Feb 17 2012 Dave Jones +- Reenable radio drivers. (rhbz 784824) + * Thu Feb 16 2012 Dave Jones 3.2.6-4 - Freeze all filesystems during system suspend/hibernate. diff --git a/freed-ora/current/f16/lis3-improve-handling-of-null-rate.patch b/freed-ora/current/f16/lis3-improve-handling-of-null-rate.patch new file mode 100644 index 000000000..98512564a --- /dev/null +++ b/freed-ora/current/f16/lis3-improve-handling-of-null-rate.patch @@ -0,0 +1,79 @@ +>From 56fb161a9ca0129f8e266e4dbe79346552ff8089 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?=C3=89ric=20Piel?= +Date: Thu, 3 Nov 2011 16:22:40 +0100 +Subject: [PATCH] lis3: Improve handling of null rate +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +When obtaining a rate of 0, we would disable the device supposely +because it seems to behave incorectly. It actually only comes from the +fact that the device is off and on lis3dc it's reflected in the rate. +So handle this nicely by just waiting a safe time, and then using the +device as normally. + +Signed-off-by: ??ric Piel +--- + drivers/misc/lis3lv02d/lis3lv02d.c | 16 ++++++++-------- + 1 files changed, 8 insertions(+), 8 deletions(-) + +diff --git a/drivers/misc/lis3lv02d/lis3lv02d.c b/drivers/misc/lis3lv02d/lis3lv02d.c +index 35c67e0..42dce2a 100644 +--- a/drivers/misc/lis3lv02d/lis3lv02d.c ++++ b/drivers/misc/lis3lv02d/lis3lv02d.c +@@ -188,7 +188,8 @@ static void lis3lv02d_get_xyz(struct lis3lv02d *lis3, int *x, int *y, int *z) + /* conversion btw sampling rate and the register values */ + static int lis3_12_rates[4] = {40, 160, 640, 2560}; + static int lis3_8_rates[2] = {100, 400}; +-static int lis3_3dc_rates[16] = {0, 1, 10, 25, 50, 100, 200, 400, 1600, 5000}; ++/* LIS3DC: 0 = power off, above 9 = undefined */ ++static int lis3_3dc_rates[16] = {0, 1, 10, 25, 50, 100, 200, 400, 1600, 5000, -1, -1, -1, -1, -1, -1}; + + /* ODR is Output Data Rate */ + static int lis3lv02d_get_odr(struct lis3lv02d *lis3) +@@ -202,12 +203,11 @@ static int lis3lv02d_get_odr(struct lis3lv02d *lis3) + return lis3->odrs[(ctrl >> shift)]; + } + +-static int lis3lv02d_get_pwron_wait(struct lis3lv02d *lis3) ++static int lis3lv02d_wait_pwron(struct lis3lv02d *lis3) + { + int div = lis3lv02d_get_odr(lis3); +- +- if (WARN_ONCE(div == 0, "device returned spurious data")) +- return -ENXIO; ++ if (div <= 0) ++ div = 1; /* maximum delay */ + + /* LIS3 power on delay is quite long */ + msleep(lis3->pwron_delay / div); +@@ -274,7 +274,7 @@ static int lis3lv02d_selftest(struct lis3lv02d *lis3, s16 results[3]) + + lis3->read(lis3, ctlreg, ®); + lis3->write(lis3, ctlreg, (reg | selftest)); +- ret = lis3lv02d_get_pwron_wait(lis3); ++ ret = lis3lv02d_wait_pwron(lis3); + if (ret) + goto fail; + +@@ -285,7 +285,7 @@ static int lis3lv02d_selftest(struct lis3lv02d *lis3, s16 results[3]) + + /* back to normal settings */ + lis3->write(lis3, ctlreg, reg); +- ret = lis3lv02d_get_pwron_wait(lis3); ++ ret = lis3lv02d_wait_pwron(lis3); + if (ret) + goto fail; + +@@ -397,7 +397,7 @@ int lis3lv02d_poweron(struct lis3lv02d *lis3) + lis3->write(lis3, CTRL_REG2, reg); + } + +- err = lis3lv02d_get_pwron_wait(lis3); ++ err = lis3lv02d_wait_pwron(lis3); + if (err) + return err; + +-- +1.7.7.1 + diff --git a/freed-ora/current/f16/nfs-oops-getacl.patch b/freed-ora/current/f16/nfs-oops-getacl.patch new file mode 100644 index 000000000..53e599dd4 --- /dev/null +++ b/freed-ora/current/f16/nfs-oops-getacl.patch @@ -0,0 +1,96 @@ +From 331818f1c468a24e581aedcbe52af799366a9dfe Mon Sep 17 00:00:00 2001 +From: Trond Myklebust +Date: Fri, 3 Feb 2012 18:30:53 -0500 +Subject: [PATCH] NFSv4: Fix an Oops in the NFSv4 getacl code + +Commit bf118a342f10dafe44b14451a1392c3254629a1f (NFSv4: include bitmap +in nfsv4 get acl data) introduces the 'acl_scratch' page for the case +where we may need to decode multi-page data. However it fails to take +into account the fact that the variable may be NULL (for the case where +we're not doing multi-page decode), and it also attaches it to the +encoding xdr_stream rather than the decoding one. + +The immediate result is an Oops in nfs4_xdr_enc_getacl due to the +call to page_address() with a NULL page pointer. + +Signed-off-by: Trond Myklebust +Cc: Andy Adamson +Cc: stable@vger.kernel.org +--- + fs/nfs/nfs4proc.c | 8 ++++---- + fs/nfs/nfs4xdr.c | 5 ++++- + include/linux/nfs_xdr.h | 2 +- + 3 files changed, 9 insertions(+), 6 deletions(-) + +diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c +index f0c849c..d202e04 100644 +--- a/fs/nfs/nfs4proc.c ++++ b/fs/nfs/nfs4proc.c +@@ -3575,8 +3575,8 @@ static ssize_t __nfs4_get_acl_uncached(struct inode *inode, void *buf, size_t bu + } + if (npages > 1) { + /* for decoding across pages */ +- args.acl_scratch = alloc_page(GFP_KERNEL); +- if (!args.acl_scratch) ++ res.acl_scratch = alloc_page(GFP_KERNEL); ++ if (!res.acl_scratch) + goto out_free; + } + args.acl_len = npages * PAGE_SIZE; +@@ -3612,8 +3612,8 @@ out_free: + for (i = 0; i < npages; i++) + if (pages[i]) + __free_page(pages[i]); +- if (args.acl_scratch) +- __free_page(args.acl_scratch); ++ if (res.acl_scratch) ++ __free_page(res.acl_scratch); + return ret; + } + +diff --git a/fs/nfs/nfs4xdr.c b/fs/nfs/nfs4xdr.c +index 95e92e4..33bd8d0 100644 +--- a/fs/nfs/nfs4xdr.c ++++ b/fs/nfs/nfs4xdr.c +@@ -2522,7 +2522,6 @@ static void nfs4_xdr_enc_getacl(struct rpc_rqst *req, struct xdr_stream *xdr, + + xdr_inline_pages(&req->rq_rcv_buf, replen << 2, + args->acl_pages, args->acl_pgbase, args->acl_len); +- xdr_set_scratch_buffer(xdr, page_address(args->acl_scratch), PAGE_SIZE); + + encode_nops(&hdr); + } +@@ -6032,6 +6031,10 @@ nfs4_xdr_dec_getacl(struct rpc_rqst *rqstp, struct xdr_stream *xdr, + struct compound_hdr hdr; + int status; + ++ if (res->acl_scratch != NULL) { ++ void *p = page_address(res->acl_scratch); ++ xdr_set_scratch_buffer(xdr, p, PAGE_SIZE); ++ } + status = decode_compound_hdr(xdr, &hdr); + if (status) + goto out; +diff --git a/include/linux/nfs_xdr.h b/include/linux/nfs_xdr.h +index a764cef..d6ba9a1 100644 +--- a/include/linux/nfs_xdr.h ++++ b/include/linux/nfs_xdr.h +@@ -614,7 +614,6 @@ struct nfs_getaclargs { + size_t acl_len; + unsigned int acl_pgbase; + struct page ** acl_pages; +- struct page * acl_scratch; + struct nfs4_sequence_args seq_args; + }; + +@@ -624,6 +623,7 @@ struct nfs_getaclres { + size_t acl_len; + size_t acl_data_offset; + int acl_flags; ++ struct page * acl_scratch; + struct nfs4_sequence_res seq_res; + }; + +-- +1.7.4.1 + diff --git a/freed-ora/current/f16/patch-libre-3.2.6.xz.sign b/freed-ora/current/f16/patch-libre-3.2.6.xz.sign deleted file mode 100644 index 5c918d4f1..000000000 --- a/freed-ora/current/f16/patch-libre-3.2.6.xz.sign +++ /dev/null @@ -1,7 +0,0 @@ ------BEGIN PGP SIGNATURE----- -Version: GnuPG v2.0.18 (GNU/Linux) - -iEYEABECAAYFAk85iY8ACgkQvLfPh359R6f3FACfd+vUEJjlaiV3ZSvOyXaSY07A -1g4An0bCgZmI8rVC0OAvisF98DMpz1d1 -=3/yS ------END PGP SIGNATURE----- diff --git a/freed-ora/current/f16/patch-libre-3.2.7.xz.sign b/freed-ora/current/f16/patch-libre-3.2.7.xz.sign new file mode 100644 index 000000000..45c6ac279 --- /dev/null +++ b/freed-ora/current/f16/patch-libre-3.2.7.xz.sign @@ -0,0 +1,7 @@ +-----BEGIN PGP SIGNATURE----- +Version: GnuPG v2.0.18 (GNU/Linux) + +iEYEABECAAYFAk9DJVUACgkQvLfPh359R6eREACePjQx6SGsvB16STrRayfFmvB2 +3icAnjeOPjaYduMAr2dGHbucMcddJLFH +=W/2z +-----END PGP SIGNATURE----- diff --git a/freed-ora/current/f16/scsi-fix-sd_revalidate_disk-oops.patch b/freed-ora/current/f16/scsi-fix-sd_revalidate_disk-oops.patch new file mode 100644 index 000000000..defa240a2 --- /dev/null +++ b/freed-ora/current/f16/scsi-fix-sd_revalidate_disk-oops.patch @@ -0,0 +1,116 @@ +--- linux-2.6.42.noarch/fs/partitions/check.c~ 2012-02-20 18:32:55.314253719 -0500 ++++ linux-2.6.42.noarch/fs/partitions/check.c 2012-02-20 18:34:46.509859745 -0500 +@@ -539,17 +539,11 @@ static bool disk_unlock_native_capacity( + } + } + +-int rescan_partitions(struct gendisk *disk, struct block_device *bdev) ++static int drop_partitions(struct gendisk *disk, struct block_device *bdev) + { +- struct parsed_partitions *state = NULL; + struct disk_part_iter piter; + struct hd_struct *part; +- int p, highest, res; +-rescan: +- if (state && !IS_ERR(state)) { +- kfree(state); +- state = NULL; +- } ++ int res; + + if (bdev->bd_part_count) + return -EBUSY; +@@ -562,6 +556,24 @@ rescan: + delete_partition(disk, part->partno); + disk_part_iter_exit(&piter); + ++ return 0; ++} ++ ++int rescan_partitions(struct gendisk *disk, struct block_device *bdev) ++{ ++ struct parsed_partitions *state = NULL; ++ struct hd_struct *part; ++ int p, highest, res; ++rescan: ++ if (state && !IS_ERR(state)) { ++ kfree(state); ++ state = NULL; ++ } ++ ++ res = drop_partitions(disk, bdev); ++ if (res) ++ return res; ++ + if (disk->fops->revalidate_disk) + disk->fops->revalidate_disk(disk); + check_disk_size_change(disk, bdev); +@@ -665,6 +677,26 @@ rescan: + return 0; + } + ++int invalidate_partitions(struct gendisk *disk, struct block_device *bdev) ++{ ++ int res; ++ ++ if (!bdev->bd_invalidated) ++ return 0; ++ ++ res = drop_partitions(disk, bdev); ++ if (res) ++ return res; ++ ++ set_capacity(disk, 0); ++ check_disk_size_change(disk, bdev); ++ bdev->bd_invalidated = 0; ++ /* tell userspace that the media / partition table may have changed */ ++ kobject_uevent(&disk_to_dev(disk)->kobj, KOBJ_CHANGE); ++ ++ return 0; ++} ++ + unsigned char *read_dev_sector(struct block_device *bdev, sector_t n, Sector *p) + { + struct address_space *mapping = bdev->bd_inode->i_mapping; +--- linux-2.6.42.noarch/include/linux/genhd.h~ 2012-02-20 18:35:02.777802107 -0500 ++++ linux-2.6.42.noarch/include/linux/genhd.h 2012-02-20 18:35:13.873762792 -0500 +@@ -596,6 +596,7 @@ extern char *disk_name (struct gendisk * + + extern int disk_expand_part_tbl(struct gendisk *disk, int target); + extern int rescan_partitions(struct gendisk *disk, struct block_device *bdev); ++extern int invalidate_partitions(struct gendisk *disk, struct block_device *bdev); + extern struct hd_struct * __must_check add_partition(struct gendisk *disk, + int partno, sector_t start, + sector_t len, int flags, +--- linux-2.6.42.noarch/fs/block_dev.c~ 2012-02-20 18:35:24.890723757 -0500 ++++ linux-2.6.42.noarch/fs/block_dev.c 2012-02-20 18:36:25.166510197 -0500 +@@ -1159,8 +1159,12 @@ static int __blkdev_get(struct block_dev + * The latter is necessary to prevent ghost + * partitions on a removed medium. + */ +- if (bdev->bd_invalidated && (!ret || ret == -ENOMEDIUM)) +- rescan_partitions(disk, bdev); ++ if (bdev->bd_invalidated) { ++ if (!ret) ++ rescan_partitions(disk, bdev); ++ else if (ret == -ENOMEDIUM) ++ invalidate_partitions(disk, bdev); ++ } + if (ret) + goto out_clear; + } else { +@@ -1190,8 +1194,12 @@ static int __blkdev_get(struct block_dev + if (bdev->bd_disk->fops->open) + ret = bdev->bd_disk->fops->open(bdev, mode); + /* the same as first opener case, read comment there */ +- if (bdev->bd_invalidated && (!ret || ret == -ENOMEDIUM)) +- rescan_partitions(bdev->bd_disk, bdev); ++ if (bdev->bd_invalidated) { ++ if (!ret) ++ rescan_partitions(bdev->bd_disk, bdev); ++ else if (ret == -ENOMEDIUM) ++ invalidate_partitions(bdev->bd_disk, bdev); ++ } + if (ret) + goto out_unlock_bdev; + } diff --git a/freed-ora/current/f16/sources b/freed-ora/current/f16/sources index 0d930fa0b..5aa7b2631 100644 --- a/freed-ora/current/f16/sources +++ b/freed-ora/current/f16/sources @@ -1,2 +1,2 @@ 27c641c4f6785fc647cdd3e44963a55c linux-3.2-libre.tar.xz -c4b411e90294fcb768d5242a6c21c0d7 patch-libre-3.2.6.xz +37a0fdc7ad19c9489faf09925b4fae5b patch-libre-3.2.7.xz -- cgit v1.2.1