Commit 2dac355c authored by Manuel's avatar Manuel

New kernel

parent 10a55456
#
# Core Packages for Chakra, part of chakra-project.org
_kver="3.9.0-1-CHAKRA"
pkgname=acpi_call
_pkgname=acpi_call
pkgver=1.0.0
pkgrel=6
pkgdesc="A kernel module that enables you to call parameterless ACPI methods by writing the method name to /proc/acpi/call, e.g. to turn off discrete graphics card in a dual graphics environment (like NVIDIA Optimus)."
arch=('x86_64')
url=("http://github.com/mkottman/acpi_call")
license=('GPL')
depends=('linux>=3.9' 'linux<3.10' 'linux-headers')
makedepends=('git')
provides=('acpi-call')
replaces=('acpi-call')
conflicts=('acpi-call')
install=acpi_call.install
source=("https://github.com/mkottman/acpi_call/archive/v${pkgver}.tar.gz")
md5sums=('3c71239792ddd725d13f7c8d168b4ecf')
build() {
cd ${srcdir}/$_pkgname-${pkgver}
make
}
package() {
cd ${srcdir}/$_pkgname-${pkgver}
install -d ${pkgdir}/usr/share/$_pkgname
install -d ${pkgdir}/usr/bin
install -Dm755 ${srcdir}/$_pkgname-${pkgver}/examples/asus1215n.sh \
${pkgdir}/usr/share/$_pkgname
install -Dm755 ${srcdir}/$_pkgname-${pkgver}/examples/m11xr2.sh \
${pkgdir}/usr/share/$_pkgname
install -Dm755 ${srcdir}/$_pkgname-${pkgver}/examples/dellL702X.sh \
${pkgdir}/usr/share/$_pkgname
install -Dm755 ${srcdir}/$_pkgname-${pkgver}/examples/turn_off_gpu.sh \
${pkgdir}/usr/share/$_pkgname
ln -s /usr/share/$_pkgname/turn_off_gpu.sh \
${pkgdir}/usr/bin/turn_off_gpu.sh
install -Dm755 ${srcdir}/$_pkgname-${pkgver}/support/query_dsdt.pl \
${pkgdir}/usr/share/$_pkgname-${pkgver}
cp -R support/windump_hack \
${pkgdir}/usr/share/$_pkgname/
install -Dm644 README.md \
${pkgdir}/usr/share/$_pkgname/README.md
msg2 "Building module for $_kver..."
# KDIR is necessary even when cleaning
#make KDIR=/usr/src/linux-${_kver} clean
make KDIR=/usr/src/linux-${_kver}
install -D -m644 acpi_call.ko $pkgdir/lib/modules/${_kver}/kernel/drivers/acpi/acpi_call.ko
}
post_install() {
depmod -a
echo ""
echo "[+] modprobe acpi_call"
echo ">>> run /usr/bin/turn_off_gpu.sh to test/view different acpi_call functions to see if it disables your secondary/hybrid video card"
echo ">>> There are a few scripts to use in /usr/share/acpi_call/ - some for specific laptops => asus1215n.sh, dellL702X.sh, m11xr2.sh"
}
post_upgrade() {
depmod -a
echo ""
echo "[+] modprobe acpi_call"
echo ">>> run /usr/bin/turn_off_gpu.sh to test/view different acpi_call functions to see if it disables your secondary/hybrid video card"
echo ">>> There are a few scripts to use in /usr/share/acpi_call/ - some for specific laptops => asus1215n.sh, dellL702X.sh, m11xr2.sh"
}
post_remove() {
depmod -a
}
op=$1
shift
$op $*
# #
# Chakra Packages for Chakra, part of chakra-project.org # Chakra Packages for Chakra, part of chakra-project.org
#
# maintainer abveritas@chakra-project.org
pkgname=aufs3-util pkgname=aufs3-util
pkgver=20120607 pkgver=20120607
pkgrel=2 pkgrel=2
pkgdesc="Another Unionfs Implementation that supports NFS branches" pkgdesc="Another Unionfs Implementation that supports NFS branches"
arch=('i686' 'x86_64') arch=('x86_64')
url="http://aufs.sourceforge.net/" url="http://aufs.sourceforge.net/"
license=('GPL2') license=('GPL2')
depends=('glibc') depends=('glibc')
...@@ -19,8 +17,8 @@ md5sums=('a1012045b45ec13ccc1be231d5e76464') ...@@ -19,8 +17,8 @@ md5sums=('a1012045b45ec13ccc1be231d5e76464')
build() { build() {
cd $srcdir/aufs3-util-$pkgver cd $srcdir/aufs3-util-$pkgver
export CPPFLAGS="-I /usr/src/linux-3.4.2-1-CHAKRA/include/" export CPPFLAGS="-I /usr/src/linux-3.9.0-1-CHAKRA/include/"
make make
} }
package() { package() {
......
# #
# Core Packages for Chakra, part of chakra-project.org # Core Packages for Chakra, part of chakra-project.org
#
# maintainer abveritas@chakra-project.org
pkgbase="linux-lts" pkgbase="linux-lts"
pkgname=('linux-lts' 'linux-lts-headers' 'linux-lts-docs') # Build stock -CHAKRA-LTS kernel pkgname=('linux-lts' 'linux-lts-headers' 'linux-lts-docs') # Build stock -CHAKRA-LTS kernel
# pkgname=linux-custom # Build kernel with a different name # pkgname=linux-custom # Build kernel with a different name
_kernelname=${pkgname#linux} _kernelname=${pkgname#linux}
_basekernel=3.0 _basekernel=3.0
pkgver=3.0.62 pkgver=3.0.78
pkgrel=1 pkgrel=1
makedepends=('xmlto' 'docbook-xsl') makedepends=('xmlto' 'docbook-xsl')
arch=('x86_64') arch=('x86_64')
...@@ -35,7 +33,7 @@ source=("ftp://ftp.kernel.org/pub/linux/kernel/v3.0/linux-$_basekernel.tar.bz2" ...@@ -35,7 +33,7 @@ source=("ftp://ftp.kernel.org/pub/linux/kernel/v3.0/linux-$_basekernel.tar.bz2"
'module-symbol-waiting-3.0.patch' 'module-symbol-waiting-3.0.patch'
'module-init-wait-3.0.patch') 'module-init-wait-3.0.patch')
md5sums=('398e95866794def22b12dfbc15ce89c0' md5sums=('398e95866794def22b12dfbc15ce89c0'
'b0c86830c65280b02223fd8fff8aec08' 'e82abb9211fdf67d11dff1e9498bb26c'
'2d787099d3a44531bcb3ab39aee5539e' '2d787099d3a44531bcb3ab39aee5539e'
'4925d736212481eb1f7b318ef9e8b95f' '4925d736212481eb1f7b318ef9e8b95f'
'821e1112493f187dc70df9412e61f324' '821e1112493f187dc70df9412e61f324'
...@@ -311,4 +309,4 @@ package_linux-lts-docs() { ...@@ -311,4 +309,4 @@ package_linux-lts-docs() {
# remove a file already in linux package # remove a file already in linux package
rm -f "${pkgdir}/usr/src/linux-${_kernver}/Documentation/DocBook/Makefile" rm -f "${pkgdir}/usr/src/linux-${_kernver}/Documentation/DocBook/Makefile"
} }
\ No newline at end of file
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
# arg 2: the old package version # arg 2: the old package version
KERNEL_NAME=-lts KERNEL_NAME=-lts
KERNEL_VERSION=3.0.62-1-lts KERNEL_VERSION=3.0.78-1-lts
post_install () { post_install () {
# updating module dependencies # updating module dependencies
......
...@@ -7,7 +7,7 @@ pkgbase=linux ...@@ -7,7 +7,7 @@ pkgbase=linux
pkgname=('linux' 'linux-headers' 'linux-docs') pkgname=('linux' 'linux-headers' 'linux-docs')
_kernelname=${pkgname#linux} _kernelname=${pkgname#linux}
_basekernel=3.9 _basekernel=3.9
pkgver=3.9.0 pkgver=3.9.2
pkgrel=1 pkgrel=1
arch=('x86_64') arch=('x86_64')
url="http://www.kernel.org/" url="http://www.kernel.org/"
...@@ -15,7 +15,7 @@ license=('GPL2') ...@@ -15,7 +15,7 @@ license=('GPL2')
makedepends=('xmlto' 'docbook-xsl') makedepends=('xmlto' 'docbook-xsl')
options=('!strip') options=('!strip')
source=("http://www.kernel.org/pub/linux/kernel/v3.x/linux-${_basekernel}.tar.xz" source=("http://www.kernel.org/pub/linux/kernel/v3.x/linux-${_basekernel}.tar.xz"
#"http://www.kernel.org/pub/linux/kernel/v3.x/patch-${pkgver}.xz" "http://www.kernel.org/pub/linux/kernel/v3.x/patch-${pkgver}.xz"
# the main kernel config files # the main kernel config files
'config.x86_64' 'config.x86_64'
#aufs patches #aufs patches
...@@ -26,21 +26,19 @@ source=("http://www.kernel.org/pub/linux/kernel/v3.x/linux-${_basekernel}.tar.xz ...@@ -26,21 +26,19 @@ source=("http://www.kernel.org/pub/linux/kernel/v3.x/linux-${_basekernel}.tar.xz
'aufs3-kbuild.patch' 'aufs3-kbuild.patch'
'aufs3.patch' 'aufs3.patch'
'config.aufs' 'config.aufs'
# Fixes
alsa-firmware-loading-3.8.8.patch
# standard config files for mkinitcpio ramdisk # standard config files for mkinitcpio ramdisk
'linux.preset' 'linux.preset'
'change-default-console-loglevel.patch') 'change-default-console-loglevel.patch')
md5sums=('4348c9b6b2eb3144d601e87c19d5d909' md5sums=('4348c9b6b2eb3144d601e87c19d5d909'
'b052c16a6f0b1861233166b9d52033d2' 'adeb2556568f79e827e7a0ce4c483605'
'52690fe8baa6d6abd858f04c4531d437' '698318024a36e40b4d44eac67c3a7ecd'
'94a873436f6c62580ac54c1b9f0e021a' '89fbb605ef398297b8dc43409c849c92'
'a2678afaf5205f24c58affd4b1570503' 'd5f57f666f02ca25ba298210e2332ce8'
'7693e0258036ab1c6e6a42d7ee573666' 'cf2ad9065886e56698524eab323ac656'
'f9d33aeebb5c637eeefc222643632035' '460247f1b4da5dccdaacfa6d161131f0'
'5e73a0f39d73095bdff6a9168ecc05cd' '498abc1e34df8a7d19e43980c74f2bc2'
'3ce07d164880e16ae622d1dadb6e5b7a'
'52f4a2c7f6277774117c834d949d6b81' '52f4a2c7f6277774117c834d949d6b81'
'e2ac681ffa439e969b4c3b4616852454'
'eb14dcfd80c00852ef81ded6e826826a' 'eb14dcfd80c00852ef81ded6e826826a'
'65cbe8e4c8efaf96dd162102e46ce81d') '65cbe8e4c8efaf96dd162102e46ce81d')
...@@ -48,7 +46,7 @@ build() { ...@@ -48,7 +46,7 @@ build() {
cd "${srcdir}/linux-${_basekernel}" cd "${srcdir}/linux-${_basekernel}"
# add upstream patch # add upstream patch
# patch -p1 -i "${srcdir}/patch-${pkgver}" patch -p1 -i "${srcdir}/patch-${pkgver}"
# add latest fixes from stable queue, if needed # add latest fixes from stable queue, if needed
# http://git.kernel.org/?p=linux/kernel/git/stable/stable-queue.git # http://git.kernel.org/?p=linux/kernel/git/stable/stable-queue.git
...@@ -58,9 +56,6 @@ build() { ...@@ -58,9 +56,6 @@ build() {
# (relevant patch sent upstream: https://lkml.org/lkml/2011/7/26/227) # (relevant patch sent upstream: https://lkml.org/lkml/2011/7/26/227)
patch -p1 -i "${srcdir}/change-default-console-loglevel.patch" patch -p1 -i "${srcdir}/change-default-console-loglevel.patch"
# Fix for alsa
patch -Np1 -i "${srcdir}/alsa-firmware-loading-3.8.8.patch"
#aufs patches for Live: #aufs patches for Live:
patch -p1 -i "${srcdir}/aufs3.patch" patch -p1 -i "${srcdir}/aufs3.patch"
patch -p1 -i "${srcdir}/aufs3-base.patch" patch -p1 -i "${srcdir}/aufs3-base.patch"
......
aufs3.x-rcN base patch aufs3.9 base patch
diff --git a/fs/file_table.c b/fs/file_table.c diff --git a/fs/file_table.c b/fs/file_table.c
index de9e965..e73287a 100644 index cd4d87a..ca5948f 100644
--- a/fs/file_table.c --- a/fs/file_table.c
+++ b/fs/file_table.c +++ b/fs/file_table.c
@@ -36,7 +36,7 @@ struct files_stat_struct files_stat = { @@ -36,7 +36,7 @@ struct files_stat_struct files_stat = {
...@@ -14,10 +14,10 @@ index de9e965..e73287a 100644 ...@@ -14,10 +14,10 @@ index de9e965..e73287a 100644
/* SLAB cache for file structures */ /* SLAB cache for file structures */
static struct kmem_cache *filp_cachep __read_mostly; static struct kmem_cache *filp_cachep __read_mostly;
diff --git a/fs/inode.c b/fs/inode.c diff --git a/fs/inode.c b/fs/inode.c
index 14084b7..ece87ed 100644 index a898b3d..e83cd1e 100644
--- a/fs/inode.c --- a/fs/inode.c
+++ b/fs/inode.c +++ b/fs/inode.c
@@ -1503,7 +1503,7 @@ static int relatime_need_update(struct vfsmount *mnt, struct inode *inode, @@ -1498,7 +1498,7 @@ static int relatime_need_update(struct vfsmount *mnt, struct inode *inode,
* This does the actual work of updating an inodes time or version. Must have * This does the actual work of updating an inodes time or version. Must have
* had called mnt_want_write() before calling this. * had called mnt_want_write() before calling this.
*/ */
...@@ -27,10 +27,10 @@ index 14084b7..ece87ed 100644 ...@@ -27,10 +27,10 @@ index 14084b7..ece87ed 100644
if (inode->i_op->update_time) if (inode->i_op->update_time)
return inode->i_op->update_time(inode, time, flags); return inode->i_op->update_time(inode, time, flags);
diff --git a/fs/splice.c b/fs/splice.c diff --git a/fs/splice.c b/fs/splice.c
index 6909d89..020c7bc 100644 index 29e394e..7117387 100644
--- a/fs/splice.c --- a/fs/splice.c
+++ b/fs/splice.c +++ b/fs/splice.c
@@ -1092,8 +1092,8 @@ EXPORT_SYMBOL(generic_splice_sendpage); @@ -1095,8 +1095,8 @@ EXPORT_SYMBOL(generic_splice_sendpage);
/* /*
* Attempt to initiate a splice from pipe to file. * Attempt to initiate a splice from pipe to file.
*/ */
...@@ -41,7 +41,7 @@ index 6909d89..020c7bc 100644 ...@@ -41,7 +41,7 @@ index 6909d89..020c7bc 100644
{ {
ssize_t (*splice_write)(struct pipe_inode_info *, struct file *, ssize_t (*splice_write)(struct pipe_inode_info *, struct file *,
loff_t *, size_t, unsigned int); loff_t *, size_t, unsigned int);
@@ -1120,9 +1120,9 @@ static long do_splice_from(struct pipe_inode_info *pipe, struct file *out, @@ -1123,9 +1123,9 @@ static long do_splice_from(struct pipe_inode_info *pipe, struct file *out,
/* /*
* Attempt to initiate a splice from a file to a pipe. * Attempt to initiate a splice from a file to a pipe.
*/ */
...@@ -55,10 +55,10 @@ index 6909d89..020c7bc 100644 ...@@ -55,10 +55,10 @@ index 6909d89..020c7bc 100644
ssize_t (*splice_read)(struct file *, loff_t *, ssize_t (*splice_read)(struct file *, loff_t *,
struct pipe_inode_info *, size_t, unsigned int); struct pipe_inode_info *, size_t, unsigned int);
diff --git a/include/linux/fs.h b/include/linux/fs.h diff --git a/include/linux/fs.h b/include/linux/fs.h
index 7617ee0..1a39c33 100644 index 2c28271..5c49108 100644
--- a/include/linux/fs.h --- a/include/linux/fs.h
+++ b/include/linux/fs.h +++ b/include/linux/fs.h
@@ -2551,6 +2551,7 @@ extern int inode_change_ok(const struct inode *, struct iattr *); @@ -2558,6 +2558,7 @@ extern int inode_change_ok(const struct inode *, struct iattr *);
extern int inode_newsize_ok(const struct inode *, loff_t offset); extern int inode_newsize_ok(const struct inode *, loff_t offset);
extern void setattr_copy(struct inode *inode, const struct iattr *attr); extern void setattr_copy(struct inode *inode, const struct iattr *attr);
......
aufs3.x-rcN kbuild patch aufs3.9 kbuild patch
diff --git a/fs/Kconfig b/fs/Kconfig diff --git a/fs/Kconfig b/fs/Kconfig
index 780725a..d460c05 100644 index 780725a..d460c05 100644
...@@ -21,3 +21,15 @@ index 9d53192..e70f08f 100644 ...@@ -21,3 +21,15 @@ index 9d53192..e70f08f 100644
obj-$(CONFIG_CEPH_FS) += ceph/ obj-$(CONFIG_CEPH_FS) += ceph/
obj-$(CONFIG_PSTORE) += pstore/ obj-$(CONFIG_PSTORE) += pstore/
+obj-$(CONFIG_AUFS_FS) += aufs/ +obj-$(CONFIG_AUFS_FS) += aufs/
diff --git a/include/uapi/linux/Kbuild b/include/uapi/linux/Kbuild
index 5c8a1d2..fea7572 100644
--- a/include/uapi/linux/Kbuild
+++ b/include/uapi/linux/Kbuild
@@ -56,6 +56,7 @@ header-y += atmppp.h
header-y += atmsap.h
header-y += atmsvc.h
header-y += audit.h
+header-y += aufs_type.h
header-y += auto_fs.h
header-y += auto_fs4.h
header-y += auxvec.h
aufs3.x-rcN loopback patch aufs3.9 loopback patch
diff --git a/drivers/block/loop.c b/drivers/block/loop.c diff --git a/drivers/block/loop.c b/drivers/block/loop.c
index ae12512..ed8295b 100644 index dfe7583..c175e22 100644
--- a/drivers/block/loop.c --- a/drivers/block/loop.c
+++ b/drivers/block/loop.c +++ b/drivers/block/loop.c
@@ -506,7 +506,7 @@ out: @@ -511,7 +511,7 @@ out:
} }
struct switch_request { struct switch_request {
...@@ -13,7 +13,7 @@ index ae12512..ed8295b 100644 ...@@ -13,7 +13,7 @@ index ae12512..ed8295b 100644
struct completion wait; struct completion wait;
}; };
@@ -568,7 +568,8 @@ static int loop_thread(void *data) @@ -573,7 +573,8 @@ static int loop_thread(void *data)
* First it needs to flush existing IO, it does this by sending a magic * First it needs to flush existing IO, it does this by sending a magic
* BIO down the pipe. The completion of this BIO does the actual switch. * BIO down the pipe. The completion of this BIO does the actual switch.
*/ */
...@@ -23,7 +23,7 @@ index ae12512..ed8295b 100644 ...@@ -23,7 +23,7 @@ index ae12512..ed8295b 100644
{ {
struct switch_request w; struct switch_request w;
struct bio *bio = bio_alloc(GFP_KERNEL, 0); struct bio *bio = bio_alloc(GFP_KERNEL, 0);
@@ -576,6 +577,7 @@ static int loop_switch(struct loop_device *lo, struct file *file) @@ -581,6 +582,7 @@ static int loop_switch(struct loop_device *lo, struct file *file)
return -ENOMEM; return -ENOMEM;
init_completion(&w.wait); init_completion(&w.wait);
w.file = file; w.file = file;
...@@ -31,7 +31,7 @@ index ae12512..ed8295b 100644 ...@@ -31,7 +31,7 @@ index ae12512..ed8295b 100644
bio->bi_private = &w; bio->bi_private = &w;
bio->bi_bdev = NULL; bio->bi_bdev = NULL;
loop_make_request(lo->lo_queue, bio); loop_make_request(lo->lo_queue, bio);
@@ -592,7 +594,7 @@ static int loop_flush(struct loop_device *lo) @@ -597,7 +599,7 @@ static int loop_flush(struct loop_device *lo)
if (!lo->lo_thread) if (!lo->lo_thread)
return 0; return 0;
...@@ -40,7 +40,7 @@ index ae12512..ed8295b 100644 ...@@ -40,7 +40,7 @@ index ae12512..ed8295b 100644
} }
/* /*
@@ -611,6 +613,7 @@ static void do_loop_switch(struct loop_device *lo, struct switch_request *p) @@ -616,6 +618,7 @@ static void do_loop_switch(struct loop_device *lo, struct switch_request *p)
mapping = file->f_mapping; mapping = file->f_mapping;
mapping_set_gfp_mask(old_file->f_mapping, lo->old_gfp_mask); mapping_set_gfp_mask(old_file->f_mapping, lo->old_gfp_mask);
lo->lo_backing_file = file; lo->lo_backing_file = file;
...@@ -48,7 +48,7 @@ index ae12512..ed8295b 100644 ...@@ -48,7 +48,7 @@ index ae12512..ed8295b 100644
lo->lo_blocksize = S_ISBLK(mapping->host->i_mode) ? lo->lo_blocksize = S_ISBLK(mapping->host->i_mode) ?
mapping->host->i_bdev->bd_block_size : PAGE_SIZE; mapping->host->i_bdev->bd_block_size : PAGE_SIZE;
lo->old_gfp_mask = mapping_gfp_mask(mapping); lo->old_gfp_mask = mapping_gfp_mask(mapping);
@@ -619,6 +622,13 @@ out: @@ -624,6 +627,13 @@ out:
complete(&p->wait); complete(&p->wait);
} }
...@@ -62,7 +62,7 @@ index ae12512..ed8295b 100644 ...@@ -62,7 +62,7 @@ index ae12512..ed8295b 100644
/* /*
* loop_change_fd switched the backing store of a loopback device to * loop_change_fd switched the backing store of a loopback device to
@@ -632,6 +642,7 @@ static int loop_change_fd(struct loop_device *lo, struct block_device *bdev, @@ -637,6 +647,7 @@ static int loop_change_fd(struct loop_device *lo, struct block_device *bdev,
unsigned int arg) unsigned int arg)
{ {
struct file *file, *old_file; struct file *file, *old_file;
...@@ -70,7 +70,7 @@ index ae12512..ed8295b 100644 ...@@ -70,7 +70,7 @@ index ae12512..ed8295b 100644
struct inode *inode; struct inode *inode;
int error; int error;
@@ -648,9 +659,16 @@ static int loop_change_fd(struct loop_device *lo, struct block_device *bdev, @@ -653,9 +664,16 @@ static int loop_change_fd(struct loop_device *lo, struct block_device *bdev,
file = fget(arg); file = fget(arg);
if (!file) if (!file)
goto out; goto out;
...@@ -87,7 +87,7 @@ index ae12512..ed8295b 100644 ...@@ -87,7 +87,7 @@ index ae12512..ed8295b 100644
error = -EINVAL; error = -EINVAL;
@@ -662,17 +680,21 @@ static int loop_change_fd(struct loop_device *lo, struct block_device *bdev, @@ -667,17 +685,21 @@ static int loop_change_fd(struct loop_device *lo, struct block_device *bdev,
goto out_putf; goto out_putf;
/* and ... switch */ /* and ... switch */
...@@ -110,7 +110,7 @@ index ae12512..ed8295b 100644 ...@@ -110,7 +110,7 @@ index ae12512..ed8295b 100644
out: out:
return error; return error;
} }
@@ -815,7 +837,7 @@ static void loop_config_discard(struct loop_device *lo) @@ -820,7 +842,7 @@ static void loop_config_discard(struct loop_device *lo)
static int loop_set_fd(struct loop_device *lo, fmode_t mode, static int loop_set_fd(struct loop_device *lo, fmode_t mode,
struct block_device *bdev, unsigned int arg) struct block_device *bdev, unsigned int arg)
{ {
...@@ -119,7 +119,7 @@ index ae12512..ed8295b 100644 ...@@ -119,7 +119,7 @@ index ae12512..ed8295b 100644
struct inode *inode; struct inode *inode;
struct address_space *mapping; struct address_space *mapping;
unsigned lo_blocksize; unsigned lo_blocksize;
@@ -830,6 +852,12 @@ static int loop_set_fd(struct loop_device *lo, fmode_t mode, @@ -835,6 +857,12 @@ static int loop_set_fd(struct loop_device *lo, fmode_t mode,
file = fget(arg); file = fget(arg);
if (!file) if (!file)
goto out; goto out;
...@@ -132,7 +132,7 @@ index ae12512..ed8295b 100644 ...@@ -132,7 +132,7 @@ index ae12512..ed8295b 100644
error = -EBUSY; error = -EBUSY;
if (lo->lo_state != Lo_unbound) if (lo->lo_state != Lo_unbound)
@@ -878,6 +906,7 @@ static int loop_set_fd(struct loop_device *lo, fmode_t mode, @@ -883,6 +911,7 @@ static int loop_set_fd(struct loop_device *lo, fmode_t mode,
lo->lo_device = bdev; lo->lo_device = bdev;
lo->lo_flags = lo_flags; lo->lo_flags = lo_flags;
lo->lo_backing_file = file; lo->lo_backing_file = file;
...@@ -140,7 +140,7 @@ index ae12512..ed8295b 100644 ...@@ -140,7 +140,7 @@ index ae12512..ed8295b 100644
lo->transfer = transfer_none; lo->transfer = transfer_none;
lo->ioctl = NULL; lo->ioctl = NULL;
lo->lo_sizelimit = 0; lo->lo_sizelimit = 0;
@@ -924,6 +953,7 @@ out_clr: @@ -934,6 +963,7 @@ out_clr:
lo->lo_thread = NULL; lo->lo_thread = NULL;
lo->lo_device = NULL; lo->lo_device = NULL;
lo->lo_backing_file = NULL; lo->lo_backing_file = NULL;
...@@ -148,7 +148,7 @@ index ae12512..ed8295b 100644 ...@@ -148,7 +148,7 @@ index ae12512..ed8295b 100644
lo->lo_flags = 0; lo->lo_flags = 0;
set_capacity(lo->lo_disk, 0); set_capacity(lo->lo_disk, 0);
invalidate_bdev(bdev); invalidate_bdev(bdev);
@@ -933,6 +963,8 @@ out_clr: @@ -943,6 +973,8 @@ out_clr:
lo->lo_state = Lo_unbound; lo->lo_state = Lo_unbound;
out_putf: out_putf:
fput(file); fput(file);
...@@ -157,7 +157,7 @@ index ae12512..ed8295b 100644 ...@@ -157,7 +157,7 @@ index ae12512..ed8295b 100644
out: out:
/* This is safe: open() is still holding a reference. */ /* This is safe: open() is still holding a reference. */
module_put(THIS_MODULE); module_put(THIS_MODULE);
@@ -979,6 +1011,7 @@ loop_init_xfer(struct loop_device *lo, struct loop_func_table *xfer, @@ -989,6 +1021,7 @@ loop_init_xfer(struct loop_device *lo, struct loop_func_table *xfer,
static int loop_clr_fd(struct loop_device *lo) static int loop_clr_fd(struct loop_device *lo)
{ {
struct file *filp = lo->lo_backing_file; struct file *filp = lo->lo_backing_file;
...@@ -165,7 +165,7 @@ index ae12512..ed8295b 100644 ...@@ -165,7 +165,7 @@ index ae12512..ed8295b 100644
gfp_t gfp = lo->old_gfp_mask; gfp_t gfp = lo->old_gfp_mask;
struct block_device *bdev = lo->lo_device; struct block_device *bdev = lo->lo_device;
@@ -1012,6 +1045,7 @@ static int loop_clr_fd(struct loop_device *lo) @@ -1022,6 +1055,7 @@ static int loop_clr_fd(struct loop_device *lo)
spin_lock_irq(&lo->lo_lock); spin_lock_irq(&lo->lo_lock);
lo->lo_backing_file = NULL; lo->lo_backing_file = NULL;
...@@ -173,7 +173,7 @@ index ae12512..ed8295b 100644 ...@@ -173,7 +173,7 @@ index ae12512..ed8295b 100644
spin_unlock_irq(&lo->lo_lock); spin_unlock_irq(&lo->lo_lock);
loop_release_xfer(lo); loop_release_xfer(lo);
@@ -1052,6 +1086,8 @@ static int loop_clr_fd(struct loop_device *lo) @@ -1064,6 +1098,8 @@ static int loop_clr_fd(struct loop_device *lo)
* bd_mutex which is usually taken before lo_ctl_mutex. * bd_mutex which is usually taken before lo_ctl_mutex.
*/ */
fput(filp); fput(filp);
...@@ -183,7 +183,7 @@ index ae12512..ed8295b 100644 ...@@ -183,7 +183,7 @@ index ae12512..ed8295b 100644
} }
diff --git a/fs/aufs/f_op.c b/fs/aufs/f_op.c diff --git a/fs/aufs/f_op.c b/fs/aufs/f_op.c
index 5c35454..88f507b 100644 index 56924c5..b832bf8 100644
--- a/fs/aufs/f_op.c --- a/fs/aufs/f_op.c
+++ b/fs/aufs/f_op.c +++ b/fs/aufs/f_op.c
@@ -352,7 +352,7 @@ static ssize_t aufs_splice_read(struct file *file, loff_t *ppos, @@ -352,7 +352,7 @@ static ssize_t aufs_splice_read(struct file *file, loff_t *ppos,
...@@ -196,10 +196,10 @@ index 5c35454..88f507b 100644 ...@@ -196,10 +196,10 @@ index 5c35454..88f507b 100644
if (file->f_mapping != h_file->f_mapping) { if (file->f_mapping != h_file->f_mapping) {
file->f_mapping = h_file->f_mapping; file->f_mapping = h_file->f_mapping;
diff --git a/fs/aufs/loop.c b/fs/aufs/loop.c diff --git a/fs/aufs/loop.c b/fs/aufs/loop.c
index 4fa75a4..a923899 100644 index ccae19c..15dc5c2 100644
--- a/fs/aufs/loop.c --- a/fs/aufs/loop.c
+++ b/fs/aufs/loop.c +++ b/fs/aufs/loop.c
@@ -131,3 +131,19 @@ void au_loopback_fin(void) @@ -133,3 +133,19 @@ void au_loopback_fin(void)
{ {
kfree(au_warn_loopback_array); kfree(au_warn_loopback_array);
} }
...@@ -242,7 +242,7 @@ index 88d019c..8707c3a 100644 ...@@ -242,7 +242,7 @@ index 88d019c..8707c3a 100644
#endif /* __KERNEL__ */ #endif /* __KERNEL__ */
diff --git a/fs/aufs/super.c b/fs/aufs/super.c diff --git a/fs/aufs/super.c b/fs/aufs/super.c
index ab4c909..8e654b8 100644 index 4f57ba0..786ffea 100644