cpupowertools ready
This commit is contained in:
Binary file not shown.
@@ -0,0 +1,19 @@
|
||||
|
||||
Adjust for cfg80211_scan_done() changes in kernel 4.8
|
||||
|
||||
Signed-off-by: Thomas Backlund <tmb@mageia.org>
|
||||
|
||||
--- linux/3rdparty/rtl8723bs/os_dep/ioctl_cfg80211.c.orig
|
||||
+++ linux/3rdparty/rtl8723bs/os_dep/ioctl_cfg80211.c
|
||||
@@ -1413,7 +1413,10 @@ void rtw_cfg80211_indicate_scan_done(str
|
||||
}
|
||||
else
|
||||
{
|
||||
- cfg80211_scan_done(pwdev_priv->scan_request, aborted);
|
||||
+ struct cfg80211_scan_info info = {
|
||||
+ .aborted = aborted,
|
||||
+ };
|
||||
+ cfg80211_scan_done(pwdev_priv->scan_request, &info);
|
||||
}
|
||||
|
||||
pwdev_priv->scan_request = NULL;
|
||||
+37
@@ -0,0 +1,37 @@
|
||||
From e461958e7a7eb8df2e022e02f782dff5f60a44d0 Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Backlund <tmb@mageia.org>
|
||||
Date: Sun, 16 Oct 2016 20:09:27 +0300
|
||||
Subject: [PATCH] Revert "include/uapi/linux/atm_zatm.h: include linux/time.h"
|
||||
|
||||
This reverts commit cf00713a655d3019be7faa184402f16c43a0fed3.
|
||||
|
||||
It causes linux-atm build breakage between glibc headers and kernel headers...
|
||||
|
||||
Fixws are in progress upstream as of:
|
||||
https://patchwork.kernel.org/patch/9294305/
|
||||
|
||||
But it's not accepted yet so it might still change, and since its uapi
|
||||
we dont want to expose changes that might never land upstream.
|
||||
|
||||
Reported by: Pascal Terjam <pterjan@gmail.com>
|
||||
Signed-off-by: Thomas Backlund <tmb@mageia.org>
|
||||
|
||||
---
|
||||
include/uapi/linux/atm_zatm.h | 1 -
|
||||
1 file changed, 1 deletion(-)
|
||||
|
||||
diff --git a/include/uapi/linux/atm_zatm.h b/include/uapi/linux/atm_zatm.h
|
||||
index 5cd4d4d..9c9c6ad 100644
|
||||
--- a/include/uapi/linux/atm_zatm.h
|
||||
+++ b/include/uapi/linux/atm_zatm.h
|
||||
@@ -14,7 +14,6 @@
|
||||
|
||||
#include <linux/atmapi.h>
|
||||
#include <linux/atmioc.h>
|
||||
-#include <linux/time.h>
|
||||
|
||||
#define ZATM_GETPOOL _IOW('a',ATMIOC_SARPRV+1,struct atmif_sioc)
|
||||
/* get pool statistics */
|
||||
--
|
||||
2.10.1
|
||||
|
||||
@@ -1,37 +0,0 @@
|
||||
From 56e74338a535cbcc2f2da08b1ea1a92920194364 Mon Sep 17 00:00:00 2001
|
||||
From: Alexandra Yates <alexandra.yates@linux.intel.com>
|
||||
Date: Tue, 3 Nov 2015 14:14:18 -0800
|
||||
Subject: [PATCH] ahci: add new Intel device IDs
|
||||
|
||||
Adding Intel codename Lewisburg platform device IDs for SATA.
|
||||
|
||||
Signed-off-by: Alexandra Yates <alexandra.yates@linux.intel.com>
|
||||
Signed-off-by: Tejun Heo <tj@kernel.org>
|
||||
---
|
||||
drivers/ata/ahci.c | 10 ++++++++++
|
||||
1 file changed, 10 insertions(+)
|
||||
|
||||
diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c
|
||||
index ff343c4..ff02bb4 100644
|
||||
--- a/drivers/ata/ahci.c
|
||||
+++ b/drivers/ata/ahci.c
|
||||
@@ -314,6 +314,16 @@ static const struct pci_device_id ahci_pci_tbl[] = {
|
||||
{ PCI_VDEVICE(INTEL, 0x1f37), board_ahci_avn }, /* Avoton RAID */
|
||||
{ PCI_VDEVICE(INTEL, 0x1f3e), board_ahci_avn }, /* Avoton RAID */
|
||||
{ PCI_VDEVICE(INTEL, 0x1f3f), board_ahci_avn }, /* Avoton RAID */
|
||||
+ { PCI_VDEVICE(INTEL, 0xa182), board_ahci }, /* Lewisburg AHCI*/
|
||||
+ { PCI_VDEVICE(INTEL, 0xa202), board_ahci }, /* Lewisburg AHCI*/
|
||||
+ { PCI_VDEVICE(INTEL, 0xa184), board_ahci }, /* Lewisburg RAID*/
|
||||
+ { PCI_VDEVICE(INTEL, 0xa204), board_ahci }, /* Lewisburg RAID*/
|
||||
+ { PCI_VDEVICE(INTEL, 0xa186), board_ahci }, /* Lewisburg RAID*/
|
||||
+ { PCI_VDEVICE(INTEL, 0xa206), board_ahci }, /* Lewisburg RAID*/
|
||||
+ { PCI_VDEVICE(INTEL, 0x2822), board_ahci }, /* Lewisburg RAID*/
|
||||
+ { PCI_VDEVICE(INTEL, 0x2826), board_ahci }, /* Lewisburg RAID*/
|
||||
+ { PCI_VDEVICE(INTEL, 0xa18e), board_ahci }, /* Lewisburg RAID*/
|
||||
+ { PCI_VDEVICE(INTEL, 0xa20e), board_ahci }, /* Lewisburg RAID*/
|
||||
{ PCI_VDEVICE(INTEL, 0x2823), board_ahci }, /* Wellsburg RAID */
|
||||
{ PCI_VDEVICE(INTEL, 0x2827), board_ahci }, /* Wellsburg RAID */
|
||||
{ PCI_VDEVICE(INTEL, 0x8d02), board_ahci }, /* Wellsburg AHCI */
|
||||
--
|
||||
2.3.10
|
||||
|
||||
-145
@@ -1,145 +0,0 @@
|
||||
From f7c8d3a509e51f4a555371ded4957b225f1818ad Mon Sep 17 00:00:00 2001
|
||||
From: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Date: Mon, 2 May 2016 09:06:51 +0200
|
||||
Subject: [PATCH] ARM: bcm2835: dt: Add the ethernet to the device trees
|
||||
|
||||
The hub and the ethernet in its port 1 are hardwired on the board.
|
||||
|
||||
Compared to the adapters that can be plugged into the USB ports, this
|
||||
one has no serial EEPROM to store its MAC. Nevertheless, the Raspberry Pi
|
||||
has the MAC address for this adapter in its ROM, accessible from its
|
||||
firmware.
|
||||
|
||||
U-Boot can read out the address and set the local-mac-address property of the
|
||||
node with "ethernet" alias. Let's add the node so that U-Boot can do its
|
||||
business.
|
||||
|
||||
Model B rev2 and Model B+ entries were verified by me, the hierarchy and
|
||||
pid/vid pair for the Version 2 was provided by Peter Chen. Original
|
||||
Model B is a blind shot, though very likely correct.
|
||||
|
||||
Signed-off-by: Lubomir Rintel <lkundrak@v3.sk>
|
||||
Acked-by: Stephen Warren <swarren@wwwdotorg.org>
|
||||
---
|
||||
arch/arm/boot/dts/bcm2835-rpi-b-plus.dts | 1 +
|
||||
arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts | 1 +
|
||||
arch/arm/boot/dts/bcm2835-rpi-b.dts | 1 +
|
||||
arch/arm/boot/dts/bcm2836-rpi-2-b.dts | 1 +
|
||||
arch/arm/boot/dts/bcm283x-rpi-smsc9512.dtsi | 19 +++++++++++++++++++
|
||||
arch/arm/boot/dts/bcm283x-rpi-smsc9514.dtsi | 19 +++++++++++++++++++
|
||||
arch/arm/boot/dts/bcm283x.dtsi | 2 ++
|
||||
7 files changed, 44 insertions(+)
|
||||
create mode 100644 arch/arm/boot/dts/bcm283x-rpi-smsc9512.dtsi
|
||||
create mode 100644 arch/arm/boot/dts/bcm283x-rpi-smsc9514.dtsi
|
||||
|
||||
diff --git a/arch/arm/boot/dts/bcm2835-rpi-b-plus.dts b/arch/arm/boot/dts/bcm2835-rpi-b-plus.dts
|
||||
index ef54050..c3e01ce 100644
|
||||
--- a/arch/arm/boot/dts/bcm2835-rpi-b-plus.dts
|
||||
+++ b/arch/arm/boot/dts/bcm2835-rpi-b-plus.dts
|
||||
@@ -1,6 +1,7 @@
|
||||
/dts-v1/;
|
||||
#include "bcm2835.dtsi"
|
||||
#include "bcm2835-rpi.dtsi"
|
||||
+#include "bcm283x-rpi-smsc9514.dtsi"
|
||||
|
||||
/ {
|
||||
compatible = "raspberrypi,model-b-plus", "brcm,bcm2835";
|
||||
diff --git a/arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts b/arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts
|
||||
index 86f1f2f..364086a 100644
|
||||
--- a/arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts
|
||||
+++ b/arch/arm/boot/dts/bcm2835-rpi-b-rev2.dts
|
||||
@@ -1,6 +1,7 @@
|
||||
/dts-v1/;
|
||||
#include "bcm2835.dtsi"
|
||||
#include "bcm2835-rpi.dtsi"
|
||||
+#include "bcm283x-rpi-smsc9512.dtsi"
|
||||
|
||||
/ {
|
||||
compatible = "raspberrypi,model-b-rev2", "brcm,bcm2835";
|
||||
diff --git a/arch/arm/boot/dts/bcm2835-rpi-b.dts b/arch/arm/boot/dts/bcm2835-rpi-b.dts
|
||||
index 4859e9d..4420b09 100644
|
||||
--- a/arch/arm/boot/dts/bcm2835-rpi-b.dts
|
||||
+++ b/arch/arm/boot/dts/bcm2835-rpi-b.dts
|
||||
@@ -1,6 +1,7 @@
|
||||
/dts-v1/;
|
||||
#include "bcm2835.dtsi"
|
||||
#include "bcm2835-rpi.dtsi"
|
||||
+#include "bcm283x-rpi-smsc9512.dtsi"
|
||||
|
||||
/ {
|
||||
compatible = "raspberrypi,model-b", "brcm,bcm2835";
|
||||
diff --git a/arch/arm/boot/dts/bcm2836-rpi-2-b.dts b/arch/arm/boot/dts/bcm2836-rpi-2-b.dts
|
||||
index ff94666..b975f29 100644
|
||||
--- a/arch/arm/boot/dts/bcm2836-rpi-2-b.dts
|
||||
+++ b/arch/arm/boot/dts/bcm2836-rpi-2-b.dts
|
||||
@@ -1,6 +1,7 @@
|
||||
/dts-v1/;
|
||||
#include "bcm2836.dtsi"
|
||||
#include "bcm2835-rpi.dtsi"
|
||||
+#include "bcm283x-rpi-smsc9514.dtsi"
|
||||
|
||||
/ {
|
||||
compatible = "raspberrypi,2-model-b", "brcm,bcm2836";
|
||||
diff --git a/arch/arm/boot/dts/bcm283x-rpi-smsc9512.dtsi b/arch/arm/boot/dts/bcm283x-rpi-smsc9512.dtsi
|
||||
new file mode 100644
|
||||
index 0000000..12c981e
|
||||
--- /dev/null
|
||||
+++ b/arch/arm/boot/dts/bcm283x-rpi-smsc9512.dtsi
|
||||
@@ -0,0 +1,19 @@
|
||||
+/ {
|
||||
+ aliases {
|
||||
+ ethernet = ðernet;
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
+&usb {
|
||||
+ usb1@1 {
|
||||
+ compatible = "usb424,9512";
|
||||
+ reg = <1>;
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+
|
||||
+ ethernet: usbether@1 {
|
||||
+ compatible = "usb424,ec00";
|
||||
+ reg = <1>;
|
||||
+ };
|
||||
+ };
|
||||
+};
|
||||
diff --git a/arch/arm/boot/dts/bcm283x-rpi-smsc9514.dtsi b/arch/arm/boot/dts/bcm283x-rpi-smsc9514.dtsi
|
||||
new file mode 100644
|
||||
index 0000000..3f0a56e
|
||||
--- /dev/null
|
||||
+++ b/arch/arm/boot/dts/bcm283x-rpi-smsc9514.dtsi
|
||||
@@ -0,0 +1,19 @@
|
||||
+/ {
|
||||
+ aliases {
|
||||
+ ethernet = ðernet;
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
+&usb {
|
||||
+ usb1@1 {
|
||||
+ compatible = "usb424,9514";
|
||||
+ reg = <1>;
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
+
|
||||
+ ethernet: usbether@1 {
|
||||
+ compatible = "usb424,ec00";
|
||||
+ reg = <1>;
|
||||
+ };
|
||||
+ };
|
||||
+};
|
||||
diff --git a/arch/arm/boot/dts/bcm283x.dtsi b/arch/arm/boot/dts/bcm283x.dtsi
|
||||
index 8aaf193..04504b7 100644
|
||||
--- a/arch/arm/boot/dts/bcm283x.dtsi
|
||||
+++ b/arch/arm/boot/dts/bcm283x.dtsi
|
||||
@@ -287,6 +287,8 @@
|
||||
compatible = "brcm,bcm2835-usb";
|
||||
reg = <0x7e980000 0x10000>;
|
||||
interrupts = <1 9>;
|
||||
+ #address-cells = <1>;
|
||||
+ #size-cells = <0>;
|
||||
};
|
||||
|
||||
v3d: v3d@7ec00000 {
|
||||
@@ -8,13 +8,14 @@ Signed-off-by: Thomas Backlund <tmb@mageia.org>
|
||||
drivers/md/dm-raid.c | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
--- linux-2.6.38.2-mga2/drivers/md/dm-raid.c.orig 2011-03-15 03:20:32.000000000 +0200
|
||||
+++ linux-2.6.38.2-mga2/drivers/md/dm-raid.c 2011-04-02 21:52:21.331302590 +0300
|
||||
@@ -693,5 +693,7 @@ MODULE_DESCRIPTION(DM_NAME " raid4/5/6 t
|
||||
--- linux/drivers/md/dm-raid.c.orig
|
||||
+++ linux/drivers/md/dm-raid.c
|
||||
@@ -3689,6 +3689,8 @@ MODULE_ALIAS("dm-raid10");
|
||||
MODULE_ALIAS("dm-raid4");
|
||||
MODULE_ALIAS("dm-raid5");
|
||||
MODULE_ALIAS("dm-raid6");
|
||||
+MODULE_ALIAS("dm-raid45");
|
||||
+MODULE_ALIAS("dm-raid4-5");
|
||||
MODULE_AUTHOR("Neil Brown <dm-devel@redhat.com>");
|
||||
MODULE_AUTHOR("Heinz Mauelshagen <dm-devel@redhat.com>");
|
||||
MODULE_LICENSE("GPL");
|
||||
|
||||
+39
@@ -0,0 +1,39 @@
|
||||
From 5c33677c87cbe44ae04df69c4a29c1750a9ec4e5 Mon Sep 17 00:00:00 2001
|
||||
From: Andy Whitcroft <apw@canonical.com>
|
||||
Date: Tue, 11 Oct 2016 15:16:57 +0100
|
||||
Subject: [PATCH] dm raid: fix compat_features validation
|
||||
|
||||
In ecbfb9f118bce4 ("dm raid: add raid level takeover support") a new
|
||||
compatible feature flag was added. Validation for these compat_features
|
||||
was added but this only passes for new raid mappings with this feature
|
||||
flag. This causes previously created raid mappings to be failed at
|
||||
import.
|
||||
|
||||
Check compat_features for the only valid combination.
|
||||
|
||||
Fixes: ecbfb9f118bce4 ("dm raid: add raid level takeover support")
|
||||
Cc: stable@vger.kernel.org # v4.8
|
||||
Signed-off-by: Andy Whitcroft <apw@canonical.com>
|
||||
Signed-off-by: Heinz Mauelshagen <heinzm@redhat.com>
|
||||
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
|
||||
---
|
||||
drivers/md/dm-raid.c | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/drivers/md/dm-raid.c b/drivers/md/dm-raid.c
|
||||
index 8abde6b..2a39700 100644
|
||||
--- a/drivers/md/dm-raid.c
|
||||
+++ b/drivers/md/dm-raid.c
|
||||
@@ -2258,7 +2258,8 @@ static int super_validate(struct raid_set *rs, struct md_rdev *rdev)
|
||||
if (!mddev->events && super_init_validation(rs, rdev))
|
||||
return -EINVAL;
|
||||
|
||||
- if (le32_to_cpu(sb->compat_features) != FEATURE_FLAG_SUPPORTS_V190) {
|
||||
+ if (le32_to_cpu(sb->compat_features) &&
|
||||
+ le32_to_cpu(sb->compat_features) != FEATURE_FLAG_SUPPORTS_V190) {
|
||||
rs->ti->error = "Unable to assemble array: Unknown flag(s) in compatible feature flags";
|
||||
return -EINVAL;
|
||||
}
|
||||
--
|
||||
2.10.1
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
|
||||
Mark as 4.7 so we can rebuild aufs tools with matching 4.7 check
|
||||
|
||||
Signed-off-by: Thomas Backlund <tmb@mageia.org>
|
||||
|
||||
--- linux/include/uapi/linux/aufs_type.h.orig
|
||||
+++ linux/include/uapi/linux/aufs_type.h
|
||||
@@ -26,7 +26,7 @@
|
||||
|
||||
#include <linux/limits.h>
|
||||
|
||||
-#define AUFS_VERSION "4.x-rcN"
|
||||
+#define AUFS_VERSION "4.7"
|
||||
|
||||
/* todo? move this to linux-2.6.19/include/magic.h */
|
||||
#define AUFS_SUPER_MAGIC ('a' << 24 | 'u' << 16 | 'f' << 8 | 's')
|
||||
+51
-51
@@ -18,9 +18,9 @@
|
||||
security/security.c | 10 ++++++++++
|
||||
17 files changed, 41 insertions(+), 1 deletion(-)
|
||||
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/aufs/Kconfig linux-4.7-rc6-aufs-mod/fs/aufs/Kconfig
|
||||
--- linux-4.7-rc6-aufs/fs/aufs/Kconfig 2016-07-04 19:02:29.246286120 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/aufs/Kconfig 2016-07-04 19:03:53.653714965 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/aufs/Kconfig linux-4.8-aufs-mod/fs/aufs/Kconfig
|
||||
--- linux-4.8-aufs/fs/aufs/Kconfig 2016-07-04 19:02:29.246286120 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/aufs/Kconfig 2016-07-04 19:03:53.653714965 +0300
|
||||
@@ -1,5 +1,5 @@
|
||||
config AUFS_FS
|
||||
- bool "Aufs (Advanced multi layered unification filesystem) support"
|
||||
@@ -28,9 +28,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/aufs/Kconfig linux-4.7-rc6-aufs-mod/fs/aufs/Kco
|
||||
help
|
||||
Aufs is a stackable unification filesystem such as Unionfs,
|
||||
which unifies several directories and provides a merged single
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/dcache.c linux-4.7-rc6-aufs-mod/fs/dcache.c
|
||||
--- linux-4.7-rc6-aufs/fs/dcache.c 2016-07-04 19:02:29.260286196 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/dcache.c 2016-07-04 19:03:53.653714965 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/dcache.c linux-4.8-aufs-mod/fs/dcache.c
|
||||
--- linux-4.8-aufs/fs/dcache.c 2016-07-04 19:02:29.260286196 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/dcache.c 2016-07-04 19:03:53.653714965 +0300
|
||||
@@ -1310,6 +1310,7 @@ rename_retry:
|
||||
seq = 1;
|
||||
goto again;
|
||||
@@ -39,9 +39,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/dcache.c linux-4.7-rc6-aufs-mod/fs/dcache.c
|
||||
|
||||
/*
|
||||
* Search for at least 1 mount point in the dentry's subdirs.
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/exec.c linux-4.7-rc6-aufs-mod/fs/exec.c
|
||||
--- linux-4.7-rc6-aufs/fs/exec.c 2016-07-04 17:58:15.707773651 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/exec.c 2016-07-04 19:03:53.654714970 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/exec.c linux-4.8-aufs-mod/fs/exec.c
|
||||
--- linux-4.8-aufs/fs/exec.c 2016-07-04 17:58:15.707773651 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/exec.c 2016-07-04 19:03:53.654714970 +0300
|
||||
@@ -104,6 +104,7 @@ bool path_noexec(const struct path *path
|
||||
return (path->mnt->mnt_flags & MNT_NOEXEC) ||
|
||||
(path->mnt->mnt_sb->s_iflags & SB_I_NOEXEC);
|
||||
@@ -50,9 +50,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/exec.c linux-4.7-rc6-aufs-mod/fs/exec.c
|
||||
|
||||
#ifdef CONFIG_USELIB
|
||||
/*
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/fcntl.c linux-4.7-rc6-aufs-mod/fs/fcntl.c
|
||||
--- linux-4.7-rc6-aufs/fs/fcntl.c 2016-07-04 19:02:29.260286196 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/fcntl.c 2016-07-04 19:03:53.654714970 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/fcntl.c linux-4.8-aufs-mod/fs/fcntl.c
|
||||
--- linux-4.8-aufs/fs/fcntl.c 2016-07-04 19:02:29.260286196 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/fcntl.c 2016-07-04 19:03:53.654714970 +0300
|
||||
@@ -82,6 +82,7 @@ int setfl(int fd, struct file * filp, un
|
||||
out:
|
||||
return error;
|
||||
@@ -61,9 +61,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/fcntl.c linux-4.7-rc6-aufs-mod/fs/fcntl.c
|
||||
|
||||
static void f_modown(struct file *filp, struct pid *pid, enum pid_type type,
|
||||
int force)
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/file_table.c linux-4.7-rc6-aufs-mod/fs/file_table.c
|
||||
--- linux-4.7-rc6-aufs/fs/file_table.c 2016-05-16 01:43:13.000000000 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/file_table.c 2016-07-04 19:03:53.654714970 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/file_table.c linux-4.8-aufs-mod/fs/file_table.c
|
||||
--- linux-4.8-aufs/fs/file_table.c 2016-05-16 01:43:13.000000000 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/file_table.c 2016-07-04 19:03:53.654714970 +0300
|
||||
@@ -147,6 +147,7 @@ over:
|
||||
}
|
||||
return ERR_PTR(-ENFILE);
|
||||
@@ -96,9 +96,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/file_table.c linux-4.7-rc6-aufs-mod/fs/file_tab
|
||||
|
||||
void __init files_init(void)
|
||||
{
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/inode.c linux-4.7-rc6-aufs-mod/fs/inode.c
|
||||
--- linux-4.7-rc6-aufs/fs/inode.c 2016-07-04 19:02:29.261286202 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/inode.c 2016-07-04 20:51:39.805168596 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/inode.c linux-4.8-aufs-mod/fs/inode.c
|
||||
--- linux-4.8-aufs/fs/inode.c 2016-07-04 19:02:29.261286202 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/inode.c 2016-07-04 20:51:39.805168596 +0300
|
||||
@@ -1600,6 +1600,7 @@ int update_time(struct inode *inode, str
|
||||
|
||||
return update_time(inode, time, flags);
|
||||
@@ -107,9 +107,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/inode.c linux-4.7-rc6-aufs-mod/fs/inode.c
|
||||
|
||||
/**
|
||||
* touch_atime - update the access time
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/namespace.c linux-4.7-rc6-aufs-mod/fs/namespace.c
|
||||
--- linux-4.7-rc6-aufs/fs/namespace.c 2016-07-04 17:58:15.729773645 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/namespace.c 2016-07-04 19:03:53.654714970 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/namespace.c linux-4.8-aufs-mod/fs/namespace.c
|
||||
--- linux-4.8-aufs/fs/namespace.c 2016-07-04 17:58:15.729773645 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/namespace.c 2016-07-04 19:03:53.654714970 +0300
|
||||
@@ -463,6 +463,7 @@ void __mnt_drop_write(struct vfsmount *m
|
||||
mnt_dec_writers(real_mount(mnt));
|
||||
preempt_enable();
|
||||
@@ -126,9 +126,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/namespace.c linux-4.7-rc6-aufs-mod/fs/namespace
|
||||
|
||||
static void cleanup_group_ids(struct mount *mnt, struct mount *end)
|
||||
{
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/notify/group.c linux-4.7-rc6-aufs-mod/fs/notify/group.c
|
||||
--- linux-4.7-rc6-aufs/fs/notify/group.c 2016-07-04 17:58:15.742773641 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/notify/group.c 2016-07-04 19:03:53.655714975 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/notify/group.c linux-4.8-aufs-mod/fs/notify/group.c
|
||||
--- linux-4.8-aufs/fs/notify/group.c 2016-07-04 17:58:15.742773641 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/notify/group.c 2016-07-04 19:03:53.655714975 +0300
|
||||
@@ -22,6 +22,7 @@
|
||||
#include <linux/srcu.h>
|
||||
#include <linux/rculist.h>
|
||||
@@ -161,9 +161,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/notify/group.c linux-4.7-rc6-aufs-mod/fs/notify
|
||||
|
||||
int fsnotify_fasync(int fd, struct file *file, int on)
|
||||
{
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/notify/mark.c linux-4.7-rc6-aufs-mod/fs/notify/mark.c
|
||||
--- linux-4.7-rc6-aufs/fs/notify/mark.c 2016-07-04 17:58:15.742773641 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/notify/mark.c 2016-07-04 19:03:53.655714975 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/notify/mark.c linux-4.8-aufs-mod/fs/notify/mark.c
|
||||
--- linux-4.8-aufs/fs/notify/mark.c 2016-07-04 17:58:15.742773641 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/notify/mark.c 2016-07-04 19:03:53.655714975 +0300
|
||||
@@ -113,6 +113,7 @@ void fsnotify_put_mark(struct fsnotify_m
|
||||
mark->free_mark(mark);
|
||||
}
|
||||
@@ -196,9 +196,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/notify/mark.c linux-4.7-rc6-aufs-mod/fs/notify/
|
||||
|
||||
/*
|
||||
* Nothing fancy, just initialize lists and locks and counters.
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/open.c linux-4.7-rc6-aufs-mod/fs/open.c
|
||||
--- linux-4.7-rc6-aufs/fs/open.c 2016-07-04 17:58:15.746773640 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/open.c 2016-07-04 19:03:53.655714975 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/open.c linux-4.8-aufs-mod/fs/open.c
|
||||
--- linux-4.8-aufs/fs/open.c 2016-07-04 17:58:15.746773640 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/open.c 2016-07-04 19:03:53.655714975 +0300
|
||||
@@ -64,6 +64,7 @@ int do_truncate(struct dentry *dentry, l
|
||||
inode_unlock(dentry->d_inode);
|
||||
return ret;
|
||||
@@ -215,9 +215,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/open.c linux-4.7-rc6-aufs-mod/fs/open.c
|
||||
|
||||
static int do_dentry_open(struct file *f,
|
||||
struct inode *inode,
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/read_write.c linux-4.7-rc6-aufs-mod/fs/read_write.c
|
||||
--- linux-4.7-rc6-aufs/fs/read_write.c 2016-07-04 19:02:29.262286207 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/read_write.c 2016-07-04 19:03:53.655714975 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/read_write.c linux-4.8-aufs-mod/fs/read_write.c
|
||||
--- linux-4.8-aufs/fs/read_write.c 2016-07-04 19:02:29.262286207 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/read_write.c 2016-07-04 19:03:53.655714975 +0300
|
||||
@@ -525,6 +525,7 @@ vfs_readf_t vfs_readf(struct file *file)
|
||||
return new_sync_read;
|
||||
return ERR_PTR(-ENOSYS);
|
||||
@@ -234,9 +234,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/read_write.c linux-4.7-rc6-aufs-mod/fs/read_wri
|
||||
|
||||
ssize_t __kernel_write(struct file *file, const char *buf, size_t count, loff_t *pos)
|
||||
{
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/splice.c linux-4.7-rc6-aufs-mod/fs/splice.c
|
||||
--- linux-4.7-rc6-aufs/fs/splice.c 2016-07-04 19:02:29.262286207 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/splice.c 2016-07-04 19:03:53.656714979 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/splice.c linux-4.8-aufs-mod/fs/splice.c
|
||||
--- linux-4.8-aufs/fs/splice.c 2016-07-04 19:02:29.262286207 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/splice.c 2016-07-04 19:03:53.656714979 +0300
|
||||
@@ -1124,6 +1124,7 @@ long do_splice_from(struct pipe_inode_in
|
||||
|
||||
return splice_write(pipe, out, ppos, len, flags);
|
||||
@@ -253,9 +253,9 @@ diff -Nurp linux-4.7-rc6-aufs/fs/splice.c linux-4.7-rc6-aufs-mod/fs/splice.c
|
||||
|
||||
/**
|
||||
* splice_direct_to_actor - splices data directly between two non-pipes
|
||||
diff -Nurp linux-4.7-rc6-aufs/fs/xattr.c linux-4.7-rc6-aufs-mod/fs/xattr.c
|
||||
--- linux-4.7-rc6-aufs/fs/xattr.c 2016-07-04 17:58:15.754773638 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/fs/xattr.c 2016-07-04 19:03:53.656714979 +0300
|
||||
diff -Nurp linux-4.8-aufs/fs/xattr.c linux-4.8-aufs-mod/fs/xattr.c
|
||||
--- linux-4.8-aufs/fs/xattr.c 2016-07-04 17:58:15.754773638 +0300
|
||||
+++ linux-4.8-aufs-mod/fs/xattr.c 2016-07-04 19:03:53.656714979 +0300
|
||||
@@ -207,6 +207,7 @@ vfs_getxattr_alloc(struct dentry *dentry
|
||||
*xattr_value = value;
|
||||
return error;
|
||||
@@ -264,17 +264,17 @@ diff -Nurp linux-4.7-rc6-aufs/fs/xattr.c linux-4.7-rc6-aufs-mod/fs/xattr.c
|
||||
|
||||
ssize_t
|
||||
vfs_getxattr(struct dentry *dentry, const char *name, void *value, size_t size)
|
||||
diff -Nurp linux-4.7-rc6-aufs/kernel/task_work.c linux-4.7-rc6-aufs-mod/kernel/task_work.c
|
||||
--- linux-4.7-rc6-aufs/kernel/task_work.c 2016-05-16 01:43:13.000000000 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/kernel/task_work.c 2016-07-04 19:03:53.656714979 +0300
|
||||
diff -Nurp linux-4.8-aufs/kernel/task_work.c linux-4.8-aufs-mod/kernel/task_work.c
|
||||
--- linux-4.8-aufs/kernel/task_work.c 2016-05-16 01:43:13.000000000 +0300
|
||||
+++ linux-4.8-aufs-mod/kernel/task_work.c 2016-07-04 19:03:53.656714979 +0300
|
||||
@@ -118,3 +118,4 @@ void task_work_run(void)
|
||||
} while (work);
|
||||
}
|
||||
}
|
||||
+EXPORT_SYMBOL_GPL(task_work_run);
|
||||
diff -Nurp linux-4.7-rc6-aufs/security/commoncap.c linux-4.7-rc6-aufs-mod/security/commoncap.c
|
||||
--- linux-4.7-rc6-aufs/security/commoncap.c 2016-07-04 17:58:15.945773585 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/security/commoncap.c 2016-07-04 19:03:53.656714979 +0300
|
||||
diff -Nurp linux-4.8-aufs/security/commoncap.c linux-4.8-aufs-mod/security/commoncap.c
|
||||
--- linux-4.8-aufs/security/commoncap.c 2016-07-04 17:58:15.945773585 +0300
|
||||
+++ linux-4.8-aufs-mod/security/commoncap.c 2016-07-04 19:03:53.656714979 +0300
|
||||
@@ -1058,12 +1058,14 @@ int cap_mmap_addr(unsigned long addr)
|
||||
}
|
||||
return ret;
|
||||
@@ -290,9 +290,9 @@ diff -Nurp linux-4.7-rc6-aufs/security/commoncap.c linux-4.7-rc6-aufs-mod/securi
|
||||
|
||||
#ifdef CONFIG_SECURITY
|
||||
|
||||
diff -Nurp linux-4.7-rc6-aufs/security/device_cgroup.c linux-4.7-rc6-aufs-mod/security/device_cgroup.c
|
||||
--- linux-4.7-rc6-aufs/security/device_cgroup.c 2016-05-16 01:43:13.000000000 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/security/device_cgroup.c 2016-07-04 19:03:53.656714979 +0300
|
||||
diff -Nurp linux-4.8-aufs/security/device_cgroup.c linux-4.8-aufs-mod/security/device_cgroup.c
|
||||
--- linux-4.8-aufs/security/device_cgroup.c 2016-05-16 01:43:13.000000000 +0300
|
||||
+++ linux-4.8-aufs-mod/security/device_cgroup.c 2016-07-04 19:03:53.656714979 +0300
|
||||
@@ -7,6 +7,7 @@
|
||||
#include <linux/device_cgroup.h>
|
||||
#include <linux/cgroup.h>
|
||||
@@ -309,9 +309,9 @@ diff -Nurp linux-4.7-rc6-aufs/security/device_cgroup.c linux-4.7-rc6-aufs-mod/se
|
||||
|
||||
int devcgroup_inode_mknod(int mode, dev_t dev)
|
||||
{
|
||||
diff -Nurp linux-4.7-rc6-aufs/security/security.c linux-4.7-rc6-aufs-mod/security/security.c
|
||||
--- linux-4.7-rc6-aufs/security/security.c 2016-07-04 17:58:15.948773584 +0300
|
||||
+++ linux-4.7-rc6-aufs-mod/security/security.c 2016-07-04 19:03:53.657714984 +0300
|
||||
diff -Nurp linux-4.8-aufs/security/security.c linux-4.8-aufs-mod/security/security.c
|
||||
--- linux-4.8-aufs/security/security.c 2016-07-04 17:58:15.948773584 +0300
|
||||
+++ linux-4.8-aufs-mod/security/security.c 2016-07-04 19:03:53.657714984 +0300
|
||||
@@ -434,6 +434,7 @@ int security_path_rmdir(const struct pat
|
||||
return 0;
|
||||
return call_int_hook(path_rmdir, 0, dir, dentry);
|
||||
+877
-437
File diff suppressed because it is too large
Load Diff
+75
@@ -0,0 +1,75 @@
|
||||
From 5a920b85f2c6e3fd7d9dd9bb3f3345e9085e2360 Mon Sep 17 00:00:00 2001
|
||||
From: Paulo Zanoni <paulo.r.zanoni@intel.com>
|
||||
Date: Tue, 4 Oct 2016 14:37:32 -0300
|
||||
Subject: drm/i915/gen9: fix DDB partitioning for multi-screen cases
|
||||
|
||||
With the previous code we were only recomputing the DDB partitioning
|
||||
for the CRTCs included in the atomic commit, so any other active CRTCs
|
||||
would end up having their DDB registers zeroed. In this patch we make
|
||||
sure that the computed state starts as a copy of the current
|
||||
partitioning, and then we only zero the DDBs that we're actually
|
||||
going to recompute.
|
||||
|
||||
How to reproduce the bug:
|
||||
1 - Enable the primary plane on pipe A
|
||||
2 - Enable the primary plane on pipe B
|
||||
3 - Enable the cursor or sprite plane on pipe A
|
||||
|
||||
Step 3 will zero the DDB partitioning for pipe B since it's not
|
||||
included in the commit that enabled the cursor or sprite for pipe A.
|
||||
|
||||
I expect this to fix many FIFO underrun problems on gen9+.
|
||||
|
||||
v2:
|
||||
- Mention the cursor on the steps to reproduce the problem (Paulo).
|
||||
- Add Testcase tag provided by Maarten (Maarten).
|
||||
|
||||
Testcase: kms_cursor_legacy.cursorA-vs-flipB-atomic-transitions
|
||||
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96226
|
||||
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96828
|
||||
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97450
|
||||
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97596
|
||||
Bugzilla: https://www.phoronix.com/scan.php?page=news_item&px=Intel-Skylake-Multi-Screen-Woes
|
||||
Cc: stable@vger.kernel.org
|
||||
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
|
||||
Reviewed-by: Lyude <cpaul@redhat.com>
|
||||
Link: http://patchwork.freedesktop.org/patch/msgid/1475602652-17326-1-git-send-email-paulo.r.zanoni@intel.com
|
||||
|
||||
diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c
|
||||
index 7f1748a..fe6c1c6 100644
|
||||
--- a/drivers/gpu/drm/i915/intel_pm.c
|
||||
+++ b/drivers/gpu/drm/i915/intel_pm.c
|
||||
@@ -3362,13 +3362,15 @@ skl_allocate_pipe_ddb(struct intel_crtc_state *cstate,
|
||||
int num_active;
|
||||
int id, i;
|
||||
|
||||
+ /* Clear the partitioning for disabled planes. */
|
||||
+ memset(ddb->plane[pipe], 0, sizeof(ddb->plane[pipe]));
|
||||
+ memset(ddb->y_plane[pipe], 0, sizeof(ddb->y_plane[pipe]));
|
||||
+
|
||||
if (WARN_ON(!state))
|
||||
return 0;
|
||||
|
||||
if (!cstate->base.active) {
|
||||
ddb->pipe[pipe].start = ddb->pipe[pipe].end = 0;
|
||||
- memset(ddb->plane[pipe], 0, sizeof(ddb->plane[pipe]));
|
||||
- memset(ddb->y_plane[pipe], 0, sizeof(ddb->y_plane[pipe]));
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -4054,6 +4056,12 @@ skl_compute_ddb(struct drm_atomic_state *state)
|
||||
intel_state->wm_results.dirty_pipes = ~0;
|
||||
}
|
||||
|
||||
+ /*
|
||||
+ * We're not recomputing for the pipes not included in the commit, so
|
||||
+ * make sure we start with the current state.
|
||||
+ */
|
||||
+ memcpy(ddb, &dev_priv->wm.skl_hw.ddb, sizeof(*ddb));
|
||||
+
|
||||
for_each_intel_crtc_mask(dev, intel_crtc, realloc_pipes) {
|
||||
struct intel_crtc_state *cstate;
|
||||
|
||||
--
|
||||
cgit v0.10.2
|
||||
|
||||
-95
@@ -1,95 +0,0 @@
|
||||
From a36aa80f3cb2540fb1dbad6240852de4365a2e82 Mon Sep 17 00:00:00 2001
|
||||
From: Alexander Shishkin <alexander.shishkin@linux.intel.com>
|
||||
Date: Thu, 30 Jun 2016 11:51:44 +0300
|
||||
Subject: [PATCH] intel_th: Fix a deadlock in modprobing
|
||||
|
||||
Driver initialization tries to request a hub (GTH) driver module from
|
||||
its probe callback, resulting in a deadlock.
|
||||
|
||||
This patch solves the problem by adding a deferred work for requesting
|
||||
the hub module.
|
||||
|
||||
Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
|
||||
Cc: <stable@vger.kernel.org> # 4.4.x-
|
||||
---
|
||||
drivers/hwtracing/intel_th/core.c | 35 ++++++++++++++++++++++++++++++++++-
|
||||
drivers/hwtracing/intel_th/intel_th.h | 3 +++
|
||||
2 files changed, 37 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/drivers/hwtracing/intel_th/core.c b/drivers/hwtracing/intel_th/core.c
|
||||
index 1be543e..0b112ae 100644
|
||||
--- a/drivers/hwtracing/intel_th/core.c
|
||||
+++ b/drivers/hwtracing/intel_th/core.c
|
||||
@@ -465,6 +465,38 @@ static struct intel_th_subdevice {
|
||||
},
|
||||
};
|
||||
|
||||
+#ifdef CONFIG_MODULES
|
||||
+static void __intel_th_request_hub_module(struct work_struct *work)
|
||||
+{
|
||||
+ struct intel_th *th = container_of(work, struct intel_th,
|
||||
+ request_module_work);
|
||||
+
|
||||
+ request_module("intel_th_%s", th->hub->name);
|
||||
+}
|
||||
+
|
||||
+static int intel_th_request_hub_module(struct intel_th *th)
|
||||
+{
|
||||
+ INIT_WORK(&th->request_module_work, __intel_th_request_hub_module);
|
||||
+ schedule_work(&th->request_module_work);
|
||||
+
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+static void intel_th_request_hub_module_flush(struct intel_th *th)
|
||||
+{
|
||||
+ flush_work(&th->request_module_work);
|
||||
+}
|
||||
+#else
|
||||
+static inline int intel_th_request_hub_module(struct intel_th *th)
|
||||
+{
|
||||
+ return -EINVAL;
|
||||
+}
|
||||
+
|
||||
+static inline void intel_th_request_hub_module_flush(struct intel_th *th)
|
||||
+{
|
||||
+}
|
||||
+#endif /* CONFIG_MODULES */
|
||||
+
|
||||
static int intel_th_populate(struct intel_th *th, struct resource *devres,
|
||||
unsigned int ndevres, int irq)
|
||||
{
|
||||
@@ -535,7 +567,7 @@ static int intel_th_populate(struct intel_th *th, struct resource *devres,
|
||||
/* need switch driver to be loaded to enumerate the rest */
|
||||
if (subdev->type == INTEL_TH_SWITCH && !req) {
|
||||
th->hub = thdev;
|
||||
- err = request_module("intel_th_%s", subdev->name);
|
||||
+ err = intel_th_request_hub_module(th);
|
||||
if (!err)
|
||||
req++;
|
||||
}
|
||||
@@ -652,6 +684,7 @@ void intel_th_free(struct intel_th *th)
|
||||
{
|
||||
int i;
|
||||
|
||||
+ intel_th_request_hub_module_flush(th);
|
||||
for (i = 0; i < TH_SUBDEVICE_MAX; i++)
|
||||
if (th->thdev[i] != th->hub)
|
||||
intel_th_device_remove(th->thdev[i]);
|
||||
diff --git a/drivers/hwtracing/intel_th/intel_th.h b/drivers/hwtracing/intel_th/intel_th.h
|
||||
index 0df22e3..0482848 100644
|
||||
--- a/drivers/hwtracing/intel_th/intel_th.h
|
||||
+++ b/drivers/hwtracing/intel_th/intel_th.h
|
||||
@@ -205,6 +205,9 @@ struct intel_th {
|
||||
|
||||
int id;
|
||||
int major;
|
||||
+#ifdef CONFIG_MODULES
|
||||
+ struct work_struct request_module_work;
|
||||
+#endif /* CONFIG_MODULES */
|
||||
#ifdef CONFIG_INTEL_TH_DEBUG
|
||||
struct dentry *dbg;
|
||||
#endif
|
||||
--
|
||||
2.9.2
|
||||
|
||||
-32
@@ -1,32 +0,0 @@
|
||||
From 7a1a47ce35821b40f5b2ce46379ba14393bc3873 Mon Sep 17 00:00:00 2001
|
||||
From: Alexander Shishkin <alexander.shishkin@linux.intel.com>
|
||||
Date: Tue, 28 Jun 2016 18:55:23 +0300
|
||||
Subject: [PATCH] intel_th: pci: Add Kaby Lake PCH-H support
|
||||
|
||||
This adds Intel(R) Trace Hub PCI ID for Kaby Lake PCH-H.
|
||||
|
||||
Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
|
||||
Cc: <stable@vger.kernel.org>
|
||||
---
|
||||
drivers/hwtracing/intel_th/pci.c | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/drivers/hwtracing/intel_th/pci.c b/drivers/hwtracing/intel_th/pci.c
|
||||
index 5e25c7e..0bba384 100644
|
||||
--- a/drivers/hwtracing/intel_th/pci.c
|
||||
+++ b/drivers/hwtracing/intel_th/pci.c
|
||||
@@ -80,6 +80,11 @@ static const struct pci_device_id intel_th_pci_id_table[] = {
|
||||
PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x1a8e),
|
||||
.driver_data = (kernel_ulong_t)0,
|
||||
},
|
||||
+ {
|
||||
+ /* Kaby Lake PCH-H */
|
||||
+ PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0xa2a6),
|
||||
+ .driver_data = (kernel_ulong_t)0,
|
||||
+ },
|
||||
{ 0 },
|
||||
};
|
||||
|
||||
--
|
||||
2.9.2
|
||||
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
From 9f692cbe4a01dd9e3c3e954ec6b59662b68f9ce4 Mon Sep 17 00:00:00 2001
|
||||
From: Laura Abbott <labbott@redhat.com>
|
||||
Date: Fri, 9 Sep 2016 10:19:02 -0700
|
||||
Subject: [PATCH] cpupower: Correct return type of cpu_power_is_cpu_online in
|
||||
cpufreq
|
||||
To: Thomas Renninger <trenn@suse.com>
|
||||
Cc: linux-pm@vger.kernel.org
|
||||
Cc: linux-kernel@vger.kernel.org
|
||||
|
||||
When converting to a shared library in ac5a181d065d ("cpupower: Add
|
||||
cpuidle parts into library"), cpu_freq_cpu_exists was converted to
|
||||
cpupower_is_cpu_online. cpu_req_cpu_exists returned 0 on success and
|
||||
-ENOSYS on failure whereas cpupower_is_cpu_online returns 1 on success.
|
||||
Check for the correct return value in cpufreq-set.
|
||||
|
||||
See https://bugzilla.redhat.com/show_bug.cgi?id=1374212
|
||||
|
||||
Fixes: ac5a181d065d ("cpupower: Add cpuidle parts into library")
|
||||
Reported-by: Julian Seward <jseward@acm.org>
|
||||
Signed-off-by: Laura Abbott <labbott@redhat.com>
|
||||
---
|
||||
tools/power/cpupower/utils/cpufreq-set.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/tools/power/cpupower/utils/cpufreq-set.c b/tools/power/cpupower/utils/cpufreq-set.c
|
||||
index b4bf769..8971d71 100644
|
||||
--- a/tools/power/cpupower/utils/cpufreq-set.c
|
||||
+++ b/tools/power/cpupower/utils/cpufreq-set.c
|
||||
@@ -296,7 +296,7 @@ int cmd_freq_set(int argc, char **argv)
|
||||
struct cpufreq_affected_cpus *cpus;
|
||||
|
||||
if (!bitmask_isbitset(cpus_chosen, cpu) ||
|
||||
- cpupower_is_cpu_online(cpu))
|
||||
+ cpupower_is_cpu_online(cpu) != 1)
|
||||
continue;
|
||||
|
||||
cpus = cpufreq_get_related_cpus(cpu);
|
||||
@@ -316,7 +316,7 @@ int cmd_freq_set(int argc, char **argv)
|
||||
cpu <= bitmask_last(cpus_chosen); cpu++) {
|
||||
|
||||
if (!bitmask_isbitset(cpus_chosen, cpu) ||
|
||||
- cpupower_is_cpu_online(cpu))
|
||||
+ cpupower_is_cpu_online(cpu) != 1)
|
||||
continue;
|
||||
|
||||
if (cpupower_is_cpu_online(cpu) != 1)
|
||||
--
|
||||
2.10.0
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,242 @@
|
||||
From fcd91dd449867c6bfe56a81cabba76b829fd05cd Mon Sep 17 00:00:00 2001
|
||||
From: Sabrina Dubroca <sd@queasysnail.net>
|
||||
Date: Thu, 20 Oct 2016 15:58:02 +0200
|
||||
Subject: [PATCH] net: add recursion limit to GRO
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Currently, GRO can do unlimited recursion through the gro_receive
|
||||
handlers. This was fixed for tunneling protocols by limiting tunnel GRO
|
||||
to one level with encap_mark, but both VLAN and TEB still have this
|
||||
problem. Thus, the kernel is vulnerable to a stack overflow, if we
|
||||
receive a packet composed entirely of VLAN headers.
|
||||
|
||||
This patch adds a recursion counter to the GRO layer to prevent stack
|
||||
overflow. When a gro_receive function hits the recursion limit, GRO is
|
||||
aborted for this skb and it is processed normally. This recursion
|
||||
counter is put in the GRO CB, but could be turned into a percpu counter
|
||||
if we run out of space in the CB.
|
||||
|
||||
Thanks to Vladimír Beneš <vbenes@redhat.com> for the initial bug report.
|
||||
|
||||
Fixes: CVE-2016-7039
|
||||
Fixes: 9b174d88c257 ("net: Add Transparent Ethernet Bridging GRO support.")
|
||||
Fixes: 66e5133f19e9 ("vlan: Add GRO support for non hardware accelerated vlan")
|
||||
Signed-off-by: Sabrina Dubroca <sd@queasysnail.net>
|
||||
Reviewed-by: Jiri Benc <jbenc@redhat.com>
|
||||
Acked-by: Hannes Frederic Sowa <hannes@stressinduktion.org>
|
||||
Acked-by: Tom Herbert <tom@herbertland.com>
|
||||
Signed-off-by: David S. Miller <davem@davemloft.net>
|
||||
---
|
||||
drivers/net/geneve.c | 2 +-
|
||||
drivers/net/vxlan.c | 2 +-
|
||||
include/linux/netdevice.h | 39 ++++++++++++++++++++++++++++++++++++++-
|
||||
net/8021q/vlan.c | 2 +-
|
||||
net/core/dev.c | 1 +
|
||||
net/ethernet/eth.c | 2 +-
|
||||
net/ipv4/af_inet.c | 2 +-
|
||||
net/ipv4/fou.c | 4 ++--
|
||||
net/ipv4/gre_offload.c | 2 +-
|
||||
net/ipv4/udp_offload.c | 2 +-
|
||||
net/ipv6/ip6_offload.c | 2 +-
|
||||
11 files changed, 49 insertions(+), 11 deletions(-)
|
||||
|
||||
diff --git a/drivers/net/geneve.c b/drivers/net/geneve.c
|
||||
index 3c20e87..16af1ce 100644
|
||||
--- a/drivers/net/geneve.c
|
||||
+++ b/drivers/net/geneve.c
|
||||
@@ -453,7 +453,7 @@ static struct sk_buff **geneve_gro_receive(struct sock *sk,
|
||||
|
||||
skb_gro_pull(skb, gh_len);
|
||||
skb_gro_postpull_rcsum(skb, gh, gh_len);
|
||||
- pp = ptype->callbacks.gro_receive(head, skb);
|
||||
+ pp = call_gro_receive(ptype->callbacks.gro_receive, head, skb);
|
||||
flush = 0;
|
||||
|
||||
out_unlock:
|
||||
diff --git a/drivers/net/vxlan.c b/drivers/net/vxlan.c
|
||||
index e7d1668..c1639a3 100644
|
||||
--- a/drivers/net/vxlan.c
|
||||
+++ b/drivers/net/vxlan.c
|
||||
@@ -583,7 +583,7 @@ static struct sk_buff **vxlan_gro_receive(struct sock *sk,
|
||||
}
|
||||
}
|
||||
|
||||
- pp = eth_gro_receive(head, skb);
|
||||
+ pp = call_gro_receive(eth_gro_receive, head, skb);
|
||||
flush = 0;
|
||||
|
||||
out:
|
||||
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
|
||||
index 465e128..91ee364 100644
|
||||
--- a/include/linux/netdevice.h
|
||||
+++ b/include/linux/netdevice.h
|
||||
@@ -2169,7 +2169,10 @@ struct napi_gro_cb {
|
||||
/* Used to determine if flush_id can be ignored */
|
||||
u8 is_atomic:1;
|
||||
|
||||
- /* 5 bit hole */
|
||||
+ /* Number of gro_receive callbacks this packet already went through */
|
||||
+ u8 recursion_counter:4;
|
||||
+
|
||||
+ /* 1 bit hole */
|
||||
|
||||
/* used to support CHECKSUM_COMPLETE for tunneling protocols */
|
||||
__wsum csum;
|
||||
@@ -2180,6 +2183,40 @@ struct napi_gro_cb {
|
||||
|
||||
#define NAPI_GRO_CB(skb) ((struct napi_gro_cb *)(skb)->cb)
|
||||
|
||||
+#define GRO_RECURSION_LIMIT 15
|
||||
+static inline int gro_recursion_inc_test(struct sk_buff *skb)
|
||||
+{
|
||||
+ return ++NAPI_GRO_CB(skb)->recursion_counter == GRO_RECURSION_LIMIT;
|
||||
+}
|
||||
+
|
||||
+typedef struct sk_buff **(*gro_receive_t)(struct sk_buff **, struct sk_buff *);
|
||||
+static inline struct sk_buff **call_gro_receive(gro_receive_t cb,
|
||||
+ struct sk_buff **head,
|
||||
+ struct sk_buff *skb)
|
||||
+{
|
||||
+ if (unlikely(gro_recursion_inc_test(skb))) {
|
||||
+ NAPI_GRO_CB(skb)->flush |= 1;
|
||||
+ return NULL;
|
||||
+ }
|
||||
+
|
||||
+ return cb(head, skb);
|
||||
+}
|
||||
+
|
||||
+typedef struct sk_buff **(*gro_receive_sk_t)(struct sock *, struct sk_buff **,
|
||||
+ struct sk_buff *);
|
||||
+static inline struct sk_buff **call_gro_receive_sk(gro_receive_sk_t cb,
|
||||
+ struct sock *sk,
|
||||
+ struct sk_buff **head,
|
||||
+ struct sk_buff *skb)
|
||||
+{
|
||||
+ if (unlikely(gro_recursion_inc_test(skb))) {
|
||||
+ NAPI_GRO_CB(skb)->flush |= 1;
|
||||
+ return NULL;
|
||||
+ }
|
||||
+
|
||||
+ return cb(sk, head, skb);
|
||||
+}
|
||||
+
|
||||
struct packet_type {
|
||||
__be16 type; /* This is really htons(ether_type). */
|
||||
struct net_device *dev; /* NULL is wildcarded here */
|
||||
diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c
|
||||
index 8de138d..f2531ad 100644
|
||||
--- a/net/8021q/vlan.c
|
||||
+++ b/net/8021q/vlan.c
|
||||
@@ -664,7 +664,7 @@ static struct sk_buff **vlan_gro_receive(struct sk_buff **head,
|
||||
|
||||
skb_gro_pull(skb, sizeof(*vhdr));
|
||||
skb_gro_postpull_rcsum(skb, vhdr, sizeof(*vhdr));
|
||||
- pp = ptype->callbacks.gro_receive(head, skb);
|
||||
+ pp = call_gro_receive(ptype->callbacks.gro_receive, head, skb);
|
||||
|
||||
out_unlock:
|
||||
rcu_read_unlock();
|
||||
diff --git a/net/core/dev.c b/net/core/dev.c
|
||||
index b09ac57..dbc8713 100644
|
||||
--- a/net/core/dev.c
|
||||
+++ b/net/core/dev.c
|
||||
@@ -4511,6 +4511,7 @@ static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff
|
||||
NAPI_GRO_CB(skb)->flush = 0;
|
||||
NAPI_GRO_CB(skb)->free = 0;
|
||||
NAPI_GRO_CB(skb)->encap_mark = 0;
|
||||
+ NAPI_GRO_CB(skb)->recursion_counter = 0;
|
||||
NAPI_GRO_CB(skb)->is_fou = 0;
|
||||
NAPI_GRO_CB(skb)->is_atomic = 1;
|
||||
NAPI_GRO_CB(skb)->gro_remcsum_start = 0;
|
||||
diff --git a/net/ethernet/eth.c b/net/ethernet/eth.c
|
||||
index 66dff5e..02acfff 100644
|
||||
--- a/net/ethernet/eth.c
|
||||
+++ b/net/ethernet/eth.c
|
||||
@@ -439,7 +439,7 @@ struct sk_buff **eth_gro_receive(struct sk_buff **head,
|
||||
|
||||
skb_gro_pull(skb, sizeof(*eh));
|
||||
skb_gro_postpull_rcsum(skb, eh, sizeof(*eh));
|
||||
- pp = ptype->callbacks.gro_receive(head, skb);
|
||||
+ pp = call_gro_receive(ptype->callbacks.gro_receive, head, skb);
|
||||
|
||||
out_unlock:
|
||||
rcu_read_unlock();
|
||||
diff --git a/net/ipv4/af_inet.c b/net/ipv4/af_inet.c
|
||||
index 1effc98..9648c97 100644
|
||||
--- a/net/ipv4/af_inet.c
|
||||
+++ b/net/ipv4/af_inet.c
|
||||
@@ -1391,7 +1391,7 @@ struct sk_buff **inet_gro_receive(struct sk_buff **head, struct sk_buff *skb)
|
||||
skb_gro_pull(skb, sizeof(*iph));
|
||||
skb_set_transport_header(skb, skb_gro_offset(skb));
|
||||
|
||||
- pp = ops->callbacks.gro_receive(head, skb);
|
||||
+ pp = call_gro_receive(ops->callbacks.gro_receive, head, skb);
|
||||
|
||||
out_unlock:
|
||||
rcu_read_unlock();
|
||||
diff --git a/net/ipv4/fou.c b/net/ipv4/fou.c
|
||||
index cf50f7e..030d153 100644
|
||||
--- a/net/ipv4/fou.c
|
||||
+++ b/net/ipv4/fou.c
|
||||
@@ -249,7 +249,7 @@ static struct sk_buff **fou_gro_receive(struct sock *sk,
|
||||
if (!ops || !ops->callbacks.gro_receive)
|
||||
goto out_unlock;
|
||||
|
||||
- pp = ops->callbacks.gro_receive(head, skb);
|
||||
+ pp = call_gro_receive(ops->callbacks.gro_receive, head, skb);
|
||||
|
||||
out_unlock:
|
||||
rcu_read_unlock();
|
||||
@@ -441,7 +441,7 @@ static struct sk_buff **gue_gro_receive(struct sock *sk,
|
||||
if (WARN_ON_ONCE(!ops || !ops->callbacks.gro_receive))
|
||||
goto out_unlock;
|
||||
|
||||
- pp = ops->callbacks.gro_receive(head, skb);
|
||||
+ pp = call_gro_receive(ops->callbacks.gro_receive, head, skb);
|
||||
flush = 0;
|
||||
|
||||
out_unlock:
|
||||
diff --git a/net/ipv4/gre_offload.c b/net/ipv4/gre_offload.c
|
||||
index 96e0efe..d5cac99 100644
|
||||
--- a/net/ipv4/gre_offload.c
|
||||
+++ b/net/ipv4/gre_offload.c
|
||||
@@ -229,7 +229,7 @@ static struct sk_buff **gre_gro_receive(struct sk_buff **head,
|
||||
/* Adjusted NAPI_GRO_CB(skb)->csum after skb_gro_pull()*/
|
||||
skb_gro_postpull_rcsum(skb, greh, grehlen);
|
||||
|
||||
- pp = ptype->callbacks.gro_receive(head, skb);
|
||||
+ pp = call_gro_receive(ptype->callbacks.gro_receive, head, skb);
|
||||
flush = 0;
|
||||
|
||||
out_unlock:
|
||||
diff --git a/net/ipv4/udp_offload.c b/net/ipv4/udp_offload.c
|
||||
index f9333c9..b2be1d9 100644
|
||||
--- a/net/ipv4/udp_offload.c
|
||||
+++ b/net/ipv4/udp_offload.c
|
||||
@@ -295,7 +295,7 @@ struct sk_buff **udp_gro_receive(struct sk_buff **head, struct sk_buff *skb,
|
||||
|
||||
skb_gro_pull(skb, sizeof(struct udphdr)); /* pull encapsulating udp header */
|
||||
skb_gro_postpull_rcsum(skb, uh, sizeof(struct udphdr));
|
||||
- pp = udp_sk(sk)->gro_receive(sk, head, skb);
|
||||
+ pp = call_gro_receive_sk(udp_sk(sk)->gro_receive, sk, head, skb);
|
||||
|
||||
out_unlock:
|
||||
rcu_read_unlock();
|
||||
diff --git a/net/ipv6/ip6_offload.c b/net/ipv6/ip6_offload.c
|
||||
index e7bfd55..1fcf61f 100644
|
||||
--- a/net/ipv6/ip6_offload.c
|
||||
+++ b/net/ipv6/ip6_offload.c
|
||||
@@ -246,7 +246,7 @@ static struct sk_buff **ipv6_gro_receive(struct sk_buff **head,
|
||||
|
||||
skb_gro_postpull_rcsum(skb, iph, nlen);
|
||||
|
||||
- pp = ops->callbacks.gro_receive(head, skb);
|
||||
+ pp = call_gro_receive(ops->callbacks.gro_receive, head, skb);
|
||||
|
||||
out_unlock:
|
||||
rcu_read_unlock();
|
||||
--
|
||||
2.10.1
|
||||
|
||||
+429
@@ -0,0 +1,429 @@
|
||||
From cf4747d7535a936105f0abe8d8109d3fe339162b Mon Sep 17 00:00:00 2001
|
||||
From: Larry Finger <Larry.Finger@lwfinger.net>
|
||||
Date: Wed, 12 Oct 2016 13:54:04 -0500
|
||||
Subject: [PATCH] rtlwifi: Fix regression caused by commit d86e64768859
|
||||
|
||||
In commit d86e64768859 ("rtlwifi: rtl818x: constify local structures"),
|
||||
the configuration struct for most of the drivers was changed to be
|
||||
constant. The problem is that five of the modified drivers need to be
|
||||
able to update the firmware name based on the exact model of the card.
|
||||
As the file names were stored in one of the members of that struct,
|
||||
these drivers would fail with a kernel BUG splat when they tried to
|
||||
update the firmware name.
|
||||
|
||||
Rather than reverting the previous commit, I used a suggestion by
|
||||
Johannes Berg and made the firmware file name pointers be local to
|
||||
the routines that update the software variables.
|
||||
|
||||
The configuration struct of rtl8192cu, which was not touched in the
|
||||
previous patch, is now constantfied.
|
||||
|
||||
Fixes: d86e64768859 ("rtlwifi: rtl818x: constify local structures")
|
||||
Suggested-by: Johannes Berg <johannes@sipsolutions.net>
|
||||
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
|
||||
Cc: Stable <stable@vger.kernel.org> # 4.8
|
||||
Cc: Julia Lawall <Julia.Lawall@lip6.fr>
|
||||
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
|
||||
---
|
||||
drivers/net/wireless/realtek/rtlwifi/core.c | 2 +-
|
||||
drivers/net/wireless/realtek/rtlwifi/rtl8188ee/sw.c | 8 ++++----
|
||||
drivers/net/wireless/realtek/rtlwifi/rtl8192ce/sw.c | 13 +++++--------
|
||||
drivers/net/wireless/realtek/rtlwifi/rtl8192cu/sw.c | 12 ++++++------
|
||||
drivers/net/wireless/realtek/rtlwifi/rtl8192de/sw.c | 6 +++---
|
||||
drivers/net/wireless/realtek/rtlwifi/rtl8192ee/sw.c | 8 ++++----
|
||||
drivers/net/wireless/realtek/rtlwifi/rtl8192se/sw.c | 9 +++++----
|
||||
drivers/net/wireless/realtek/rtlwifi/rtl8723ae/sw.c | 12 +++++-------
|
||||
drivers/net/wireless/realtek/rtlwifi/rtl8723be/sw.c | 6 +++---
|
||||
drivers/net/wireless/realtek/rtlwifi/rtl8821ae/sw.c | 18 +++++++++---------
|
||||
drivers/net/wireless/realtek/rtlwifi/wifi.h | 2 --
|
||||
11 files changed, 45 insertions(+), 51 deletions(-)
|
||||
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/core.c b/drivers/net/wireless/realtek/rtlwifi/core.c
|
||||
index f95760c..8e7f23c 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/core.c
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/core.c
|
||||
@@ -111,7 +111,7 @@ static void rtl_fw_do_work(const struct firmware *firmware, void *context,
|
||||
if (!err)
|
||||
goto found_alt;
|
||||
}
|
||||
- pr_err("Firmware %s not available\n", rtlpriv->cfg->fw_name);
|
||||
+ pr_err("Selected firmware is not available\n");
|
||||
rtlpriv->max_fw_size = 0;
|
||||
return;
|
||||
}
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/sw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/sw.c
|
||||
index e7b11b4..f361808 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/sw.c
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/sw.c
|
||||
@@ -86,6 +86,7 @@ int rtl88e_init_sw_vars(struct ieee80211_hw *hw)
|
||||
struct rtl_priv *rtlpriv = rtl_priv(hw);
|
||||
struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
|
||||
u8 tid;
|
||||
+ char *fw_name;
|
||||
|
||||
rtl8188ee_bt_reg_init(hw);
|
||||
rtlpriv->dm.dm_initialgain_enable = 1;
|
||||
@@ -169,10 +170,10 @@ int rtl88e_init_sw_vars(struct ieee80211_hw *hw)
|
||||
return 1;
|
||||
}
|
||||
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8188efw.bin";
|
||||
+ fw_name = "rtlwifi/rtl8188efw.bin";
|
||||
rtlpriv->max_fw_size = 0x8000;
|
||||
- pr_info("Using firmware %s\n", rtlpriv->cfg->fw_name);
|
||||
- err = request_firmware_nowait(THIS_MODULE, 1, rtlpriv->cfg->fw_name,
|
||||
+ pr_info("Using firmware %s\n", fw_name);
|
||||
+ err = request_firmware_nowait(THIS_MODULE, 1, fw_name,
|
||||
rtlpriv->io.dev, GFP_KERNEL, hw,
|
||||
rtl_fw_cb);
|
||||
if (err) {
|
||||
@@ -284,7 +285,6 @@ static const struct rtl_hal_cfg rtl88ee_hal_cfg = {
|
||||
.bar_id = 2,
|
||||
.write_readback = true,
|
||||
.name = "rtl88e_pci",
|
||||
- .fw_name = "rtlwifi/rtl8188efw.bin",
|
||||
.ops = &rtl8188ee_hal_ops,
|
||||
.mod_params = &rtl88ee_mod_params,
|
||||
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8192ce/sw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8192ce/sw.c
|
||||
index 87aa209..8b6e37c 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8192ce/sw.c
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192ce/sw.c
|
||||
@@ -96,6 +96,7 @@ int rtl92c_init_sw_vars(struct ieee80211_hw *hw)
|
||||
struct rtl_priv *rtlpriv = rtl_priv(hw);
|
||||
struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
|
||||
struct rtl_hal *rtlhal = rtl_hal(rtl_priv(hw));
|
||||
+ char *fw_name = "rtlwifi/rtl8192cfwU.bin";
|
||||
|
||||
rtl8192ce_bt_reg_init(hw);
|
||||
|
||||
@@ -167,15 +168,12 @@ int rtl92c_init_sw_vars(struct ieee80211_hw *hw)
|
||||
}
|
||||
|
||||
/* request fw */
|
||||
- if (IS_VENDOR_UMC_A_CUT(rtlhal->version) &&
|
||||
- !IS_92C_SERIAL(rtlhal->version))
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8192cfwU.bin";
|
||||
- else if (IS_81XXC_VENDOR_UMC_B_CUT(rtlhal->version))
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8192cfwU_B.bin";
|
||||
+ if (IS_81XXC_VENDOR_UMC_B_CUT(rtlhal->version))
|
||||
+ fw_name = "rtlwifi/rtl8192cfwU_B.bin";
|
||||
|
||||
rtlpriv->max_fw_size = 0x4000;
|
||||
- pr_info("Using firmware %s\n", rtlpriv->cfg->fw_name);
|
||||
- err = request_firmware_nowait(THIS_MODULE, 1, rtlpriv->cfg->fw_name,
|
||||
+ pr_info("Using firmware %s\n", fw_name);
|
||||
+ err = request_firmware_nowait(THIS_MODULE, 1, fw_name,
|
||||
rtlpriv->io.dev, GFP_KERNEL, hw,
|
||||
rtl_fw_cb);
|
||||
if (err) {
|
||||
@@ -262,7 +260,6 @@ static const struct rtl_hal_cfg rtl92ce_hal_cfg = {
|
||||
.bar_id = 2,
|
||||
.write_readback = true,
|
||||
.name = "rtl92c_pci",
|
||||
- .fw_name = "rtlwifi/rtl8192cfw.bin",
|
||||
.ops = &rtl8192ce_hal_ops,
|
||||
.mod_params = &rtl92ce_mod_params,
|
||||
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8192cu/sw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8192cu/sw.c
|
||||
index 7c6f7f0..f953320 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8192cu/sw.c
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192cu/sw.c
|
||||
@@ -59,6 +59,7 @@ static int rtl92cu_init_sw_vars(struct ieee80211_hw *hw)
|
||||
{
|
||||
struct rtl_priv *rtlpriv = rtl_priv(hw);
|
||||
int err;
|
||||
+ char *fw_name;
|
||||
|
||||
rtlpriv->dm.dm_initialgain_enable = true;
|
||||
rtlpriv->dm.dm_flag = 0;
|
||||
@@ -77,18 +78,18 @@ static int rtl92cu_init_sw_vars(struct ieee80211_hw *hw)
|
||||
}
|
||||
if (IS_VENDOR_UMC_A_CUT(rtlpriv->rtlhal.version) &&
|
||||
!IS_92C_SERIAL(rtlpriv->rtlhal.version)) {
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8192cufw_A.bin";
|
||||
+ fw_name = "rtlwifi/rtl8192cufw_A.bin";
|
||||
} else if (IS_81XXC_VENDOR_UMC_B_CUT(rtlpriv->rtlhal.version)) {
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8192cufw_B.bin";
|
||||
+ fw_name = "rtlwifi/rtl8192cufw_B.bin";
|
||||
} else {
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8192cufw_TMSC.bin";
|
||||
+ fw_name = "rtlwifi/rtl8192cufw_TMSC.bin";
|
||||
}
|
||||
/* provide name of alternative file */
|
||||
rtlpriv->cfg->alt_fw_name = "rtlwifi/rtl8192cufw.bin";
|
||||
- pr_info("Loading firmware %s\n", rtlpriv->cfg->fw_name);
|
||||
+ pr_info("Loading firmware %s\n", fw_name);
|
||||
rtlpriv->max_fw_size = 0x4000;
|
||||
err = request_firmware_nowait(THIS_MODULE, 1,
|
||||
- rtlpriv->cfg->fw_name, rtlpriv->io.dev,
|
||||
+ fw_name, rtlpriv->io.dev,
|
||||
GFP_KERNEL, hw, rtl_fw_cb);
|
||||
return err;
|
||||
}
|
||||
@@ -187,7 +188,6 @@ static struct rtl_hal_usbint_cfg rtl92cu_interface_cfg = {
|
||||
|
||||
static struct rtl_hal_cfg rtl92cu_hal_cfg = {
|
||||
.name = "rtl92c_usb",
|
||||
- .fw_name = "rtlwifi/rtl8192cufw.bin",
|
||||
.ops = &rtl8192cu_hal_ops,
|
||||
.mod_params = &rtl92cu_mod_params,
|
||||
.usb_interface_cfg = &rtl92cu_interface_cfg,
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8192de/sw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8192de/sw.c
|
||||
index 0538a4d..1ebfee1 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8192de/sw.c
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192de/sw.c
|
||||
@@ -92,6 +92,7 @@ static int rtl92d_init_sw_vars(struct ieee80211_hw *hw)
|
||||
u8 tid;
|
||||
struct rtl_priv *rtlpriv = rtl_priv(hw);
|
||||
struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
|
||||
+ char *fw_name = "rtlwifi/rtl8192defw.bin";
|
||||
|
||||
rtlpriv->dm.dm_initialgain_enable = true;
|
||||
rtlpriv->dm.dm_flag = 0;
|
||||
@@ -181,10 +182,10 @@ static int rtl92d_init_sw_vars(struct ieee80211_hw *hw)
|
||||
|
||||
rtlpriv->max_fw_size = 0x8000;
|
||||
pr_info("Driver for Realtek RTL8192DE WLAN interface\n");
|
||||
- pr_info("Loading firmware file %s\n", rtlpriv->cfg->fw_name);
|
||||
+ pr_info("Loading firmware file %s\n", fw_name);
|
||||
|
||||
/* request fw */
|
||||
- err = request_firmware_nowait(THIS_MODULE, 1, rtlpriv->cfg->fw_name,
|
||||
+ err = request_firmware_nowait(THIS_MODULE, 1, fw_name,
|
||||
rtlpriv->io.dev, GFP_KERNEL, hw,
|
||||
rtl_fw_cb);
|
||||
if (err) {
|
||||
@@ -266,7 +267,6 @@ static const struct rtl_hal_cfg rtl92de_hal_cfg = {
|
||||
.bar_id = 2,
|
||||
.write_readback = true,
|
||||
.name = "rtl8192de",
|
||||
- .fw_name = "rtlwifi/rtl8192defw.bin",
|
||||
.ops = &rtl8192de_hal_ops,
|
||||
.mod_params = &rtl92de_mod_params,
|
||||
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8192ee/sw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8192ee/sw.c
|
||||
index ac299cb..46b605de3 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8192ee/sw.c
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192ee/sw.c
|
||||
@@ -91,6 +91,7 @@ int rtl92ee_init_sw_vars(struct ieee80211_hw *hw)
|
||||
struct rtl_priv *rtlpriv = rtl_priv(hw);
|
||||
struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
|
||||
int err = 0;
|
||||
+ char *fw_name;
|
||||
|
||||
rtl92ee_bt_reg_init(hw);
|
||||
rtlpci->msi_support = rtlpriv->cfg->mod_params->msi_support;
|
||||
@@ -170,11 +171,11 @@ int rtl92ee_init_sw_vars(struct ieee80211_hw *hw)
|
||||
}
|
||||
|
||||
/* request fw */
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8192eefw.bin";
|
||||
+ fw_name = "rtlwifi/rtl8192eefw.bin";
|
||||
|
||||
rtlpriv->max_fw_size = 0x8000;
|
||||
- pr_info("Using firmware %s\n", rtlpriv->cfg->fw_name);
|
||||
- err = request_firmware_nowait(THIS_MODULE, 1, rtlpriv->cfg->fw_name,
|
||||
+ pr_info("Using firmware %s\n", fw_name);
|
||||
+ err = request_firmware_nowait(THIS_MODULE, 1, fw_name,
|
||||
rtlpriv->io.dev, GFP_KERNEL, hw,
|
||||
rtl_fw_cb);
|
||||
if (err) {
|
||||
@@ -266,7 +267,6 @@ static const struct rtl_hal_cfg rtl92ee_hal_cfg = {
|
||||
.bar_id = 2,
|
||||
.write_readback = true,
|
||||
.name = "rtl92ee_pci",
|
||||
- .fw_name = "rtlwifi/rtl8192eefw.bin",
|
||||
.ops = &rtl8192ee_hal_ops,
|
||||
.mod_params = &rtl92ee_mod_params,
|
||||
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8192se/sw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8192se/sw.c
|
||||
index 5e8e02d..3e1eaea 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8192se/sw.c
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8192se/sw.c
|
||||
@@ -89,12 +89,13 @@ static void rtl92se_fw_cb(const struct firmware *firmware, void *context)
|
||||
struct ieee80211_hw *hw = context;
|
||||
struct rtl_priv *rtlpriv = rtl_priv(hw);
|
||||
struct rt_firmware *pfirmware = NULL;
|
||||
+ char *fw_name = "rtlwifi/rtl8192sefw.bin";
|
||||
|
||||
RT_TRACE(rtlpriv, COMP_ERR, DBG_LOUD,
|
||||
"Firmware callback routine entered!\n");
|
||||
complete(&rtlpriv->firmware_loading_complete);
|
||||
if (!firmware) {
|
||||
- pr_err("Firmware %s not available\n", rtlpriv->cfg->fw_name);
|
||||
+ pr_err("Firmware %s not available\n", fw_name);
|
||||
rtlpriv->max_fw_size = 0;
|
||||
return;
|
||||
}
|
||||
@@ -117,6 +118,7 @@ static int rtl92s_init_sw_vars(struct ieee80211_hw *hw)
|
||||
struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
|
||||
int err = 0;
|
||||
u16 earlyrxthreshold = 7;
|
||||
+ char *fw_name = "rtlwifi/rtl8192sefw.bin";
|
||||
|
||||
rtlpriv->dm.dm_initialgain_enable = true;
|
||||
rtlpriv->dm.dm_flag = 0;
|
||||
@@ -214,9 +216,9 @@ static int rtl92s_init_sw_vars(struct ieee80211_hw *hw)
|
||||
rtlpriv->max_fw_size = RTL8190_MAX_FIRMWARE_CODE_SIZE*2 +
|
||||
sizeof(struct fw_hdr);
|
||||
pr_info("Driver for Realtek RTL8192SE/RTL8191SE\n"
|
||||
- "Loading firmware %s\n", rtlpriv->cfg->fw_name);
|
||||
+ "Loading firmware %s\n", fw_name);
|
||||
/* request fw */
|
||||
- err = request_firmware_nowait(THIS_MODULE, 1, rtlpriv->cfg->fw_name,
|
||||
+ err = request_firmware_nowait(THIS_MODULE, 1, fw_name,
|
||||
rtlpriv->io.dev, GFP_KERNEL, hw,
|
||||
rtl92se_fw_cb);
|
||||
if (err) {
|
||||
@@ -310,7 +312,6 @@ static const struct rtl_hal_cfg rtl92se_hal_cfg = {
|
||||
.bar_id = 1,
|
||||
.write_readback = false,
|
||||
.name = "rtl92s_pci",
|
||||
- .fw_name = "rtlwifi/rtl8192sefw.bin",
|
||||
.ops = &rtl8192se_hal_ops,
|
||||
.mod_params = &rtl92se_mod_params,
|
||||
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8723ae/sw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8723ae/sw.c
|
||||
index 89c828a..c51a9e8 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8723ae/sw.c
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8723ae/sw.c
|
||||
@@ -94,6 +94,7 @@ int rtl8723e_init_sw_vars(struct ieee80211_hw *hw)
|
||||
struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
|
||||
struct rtl_hal *rtlhal = rtl_hal(rtl_priv(hw));
|
||||
int err = 0;
|
||||
+ char *fw_name = "rtlwifi/rtl8723fw.bin";
|
||||
|
||||
rtl8723e_bt_reg_init(hw);
|
||||
|
||||
@@ -176,14 +177,12 @@ int rtl8723e_init_sw_vars(struct ieee80211_hw *hw)
|
||||
return 1;
|
||||
}
|
||||
|
||||
- if (IS_VENDOR_8723_A_CUT(rtlhal->version))
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8723fw.bin";
|
||||
- else if (IS_81xxC_VENDOR_UMC_B_CUT(rtlhal->version))
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8723fw_B.bin";
|
||||
+ if (IS_81xxC_VENDOR_UMC_B_CUT(rtlhal->version))
|
||||
+ fw_name = "rtlwifi/rtl8723fw_B.bin";
|
||||
|
||||
rtlpriv->max_fw_size = 0x6000;
|
||||
- pr_info("Using firmware %s\n", rtlpriv->cfg->fw_name);
|
||||
- err = request_firmware_nowait(THIS_MODULE, 1, rtlpriv->cfg->fw_name,
|
||||
+ pr_info("Using firmware %s\n", fw_name);
|
||||
+ err = request_firmware_nowait(THIS_MODULE, 1, fw_name,
|
||||
rtlpriv->io.dev, GFP_KERNEL, hw,
|
||||
rtl_fw_cb);
|
||||
if (err) {
|
||||
@@ -280,7 +279,6 @@ static const struct rtl_hal_cfg rtl8723e_hal_cfg = {
|
||||
.bar_id = 2,
|
||||
.write_readback = true,
|
||||
.name = "rtl8723e_pci",
|
||||
- .fw_name = "rtlwifi/rtl8723efw.bin",
|
||||
.ops = &rtl8723e_hal_ops,
|
||||
.mod_params = &rtl8723e_mod_params,
|
||||
.maps[SYS_ISO_CTRL] = REG_SYS_ISO_CTRL,
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8723be/sw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8723be/sw.c
|
||||
index 20b53f0..847644d 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8723be/sw.c
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8723be/sw.c
|
||||
@@ -91,6 +91,7 @@ int rtl8723be_init_sw_vars(struct ieee80211_hw *hw)
|
||||
struct rtl_priv *rtlpriv = rtl_priv(hw);
|
||||
struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
|
||||
struct rtl_mac *mac = rtl_mac(rtl_priv(hw));
|
||||
+ char *fw_name = "rtlwifi/rtl8723befw.bin";
|
||||
|
||||
rtl8723be_bt_reg_init(hw);
|
||||
rtlpriv->btcoexist.btc_ops = rtl_btc_get_ops_pointer();
|
||||
@@ -184,8 +185,8 @@ int rtl8723be_init_sw_vars(struct ieee80211_hw *hw)
|
||||
}
|
||||
|
||||
rtlpriv->max_fw_size = 0x8000;
|
||||
- pr_info("Using firmware %s\n", rtlpriv->cfg->fw_name);
|
||||
- err = request_firmware_nowait(THIS_MODULE, 1, rtlpriv->cfg->fw_name,
|
||||
+ pr_info("Using firmware %s\n", fw_name);
|
||||
+ err = request_firmware_nowait(THIS_MODULE, 1, fw_name,
|
||||
rtlpriv->io.dev, GFP_KERNEL, hw,
|
||||
rtl_fw_cb);
|
||||
if (err) {
|
||||
@@ -280,7 +281,6 @@ static const struct rtl_hal_cfg rtl8723be_hal_cfg = {
|
||||
.bar_id = 2,
|
||||
.write_readback = true,
|
||||
.name = "rtl8723be_pci",
|
||||
- .fw_name = "rtlwifi/rtl8723befw.bin",
|
||||
.ops = &rtl8723be_hal_ops,
|
||||
.mod_params = &rtl8723be_mod_params,
|
||||
.maps[SYS_ISO_CTRL] = REG_SYS_ISO_CTRL,
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/sw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/sw.c
|
||||
index 22f687b1..297938e 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/sw.c
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/sw.c
|
||||
@@ -93,6 +93,7 @@ int rtl8821ae_init_sw_vars(struct ieee80211_hw *hw)
|
||||
struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw));
|
||||
struct rtl_mac *mac = rtl_mac(rtl_priv(hw));
|
||||
struct rtl_hal *rtlhal = rtl_hal(rtl_priv(hw));
|
||||
+ char *fw_name, *wowlan_fw_name;
|
||||
|
||||
rtl8821ae_bt_reg_init(hw);
|
||||
rtlpriv->btcoexist.btc_ops = rtl_btc_get_ops_pointer();
|
||||
@@ -203,17 +204,17 @@ int rtl8821ae_init_sw_vars(struct ieee80211_hw *hw)
|
||||
}
|
||||
|
||||
if (rtlhal->hw_type == HARDWARE_TYPE_RTL8812AE) {
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8812aefw.bin";
|
||||
- rtlpriv->cfg->wowlan_fw_name = "rtlwifi/rtl8812aefw_wowlan.bin";
|
||||
+ fw_name = "rtlwifi/rtl8812aefw.bin";
|
||||
+ wowlan_fw_name = "rtlwifi/rtl8812aefw_wowlan.bin";
|
||||
} else {
|
||||
- rtlpriv->cfg->fw_name = "rtlwifi/rtl8821aefw.bin";
|
||||
- rtlpriv->cfg->wowlan_fw_name = "rtlwifi/rtl8821aefw_wowlan.bin";
|
||||
+ fw_name = "rtlwifi/rtl8821aefw.bin";
|
||||
+ wowlan_fw_name = "rtlwifi/rtl8821aefw_wowlan.bin";
|
||||
}
|
||||
|
||||
rtlpriv->max_fw_size = 0x8000;
|
||||
/*load normal firmware*/
|
||||
- pr_info("Using firmware %s\n", rtlpriv->cfg->fw_name);
|
||||
- err = request_firmware_nowait(THIS_MODULE, 1, rtlpriv->cfg->fw_name,
|
||||
+ pr_info("Using firmware %s\n", fw_name);
|
||||
+ err = request_firmware_nowait(THIS_MODULE, 1, fw_name,
|
||||
rtlpriv->io.dev, GFP_KERNEL, hw,
|
||||
rtl_fw_cb);
|
||||
if (err) {
|
||||
@@ -222,9 +223,9 @@ int rtl8821ae_init_sw_vars(struct ieee80211_hw *hw)
|
||||
return 1;
|
||||
}
|
||||
/*load wowlan firmware*/
|
||||
- pr_info("Using firmware %s\n", rtlpriv->cfg->wowlan_fw_name);
|
||||
+ pr_info("Using firmware %s\n", wowlan_fw_name);
|
||||
err = request_firmware_nowait(THIS_MODULE, 1,
|
||||
- rtlpriv->cfg->wowlan_fw_name,
|
||||
+ wowlan_fw_name,
|
||||
rtlpriv->io.dev, GFP_KERNEL, hw,
|
||||
rtl_wowlan_fw_cb);
|
||||
if (err) {
|
||||
@@ -320,7 +321,6 @@ static const struct rtl_hal_cfg rtl8821ae_hal_cfg = {
|
||||
.bar_id = 2,
|
||||
.write_readback = true,
|
||||
.name = "rtl8821ae_pci",
|
||||
- .fw_name = "rtlwifi/rtl8821aefw.bin",
|
||||
.ops = &rtl8821ae_hal_ops,
|
||||
.mod_params = &rtl8821ae_mod_params,
|
||||
.maps[SYS_ISO_CTRL] = REG_SYS_ISO_CTRL,
|
||||
diff --git a/drivers/net/wireless/realtek/rtlwifi/wifi.h b/drivers/net/wireless/realtek/rtlwifi/wifi.h
|
||||
index 595f7d5..dafe486 100644
|
||||
--- a/drivers/net/wireless/realtek/rtlwifi/wifi.h
|
||||
+++ b/drivers/net/wireless/realtek/rtlwifi/wifi.h
|
||||
@@ -2278,9 +2278,7 @@ struct rtl_hal_cfg {
|
||||
u8 bar_id;
|
||||
bool write_readback;
|
||||
char *name;
|
||||
- char *fw_name;
|
||||
char *alt_fw_name;
|
||||
- char *wowlan_fw_name;
|
||||
struct rtl_hal_ops *ops;
|
||||
struct rtl_mod_params *mod_params;
|
||||
struct rtl_hal_usbint_cfg *usb_interface_cfg;
|
||||
--
|
||||
2.10.1
|
||||
|
||||
@@ -0,0 +1,111 @@
|
||||
diff --git a/drivers/nvme/host/scsi.c b/drivers/nvme/host/scsi.c
|
||||
index e947e298a737..44009105f8c8 100644
|
||||
--- a/drivers/nvme/host/scsi.c
|
||||
+++ b/drivers/nvme/host/scsi.c
|
||||
@@ -72,15 +72,6 @@ static int sg_version_num = 30534; /* 2 digits for each component */
|
||||
#define ALL_LUNS_RETURNED 0x02
|
||||
#define ALL_WELL_KNOWN_LUNS_RETURNED 0x01
|
||||
#define RESTRICTED_LUNS_RETURNED 0x00
|
||||
-#define NVME_POWER_STATE_START_VALID 0x00
|
||||
-#define NVME_POWER_STATE_ACTIVE 0x01
|
||||
-#define NVME_POWER_STATE_IDLE 0x02
|
||||
-#define NVME_POWER_STATE_STANDBY 0x03
|
||||
-#define NVME_POWER_STATE_LU_CONTROL 0x07
|
||||
-#define POWER_STATE_0 0
|
||||
-#define POWER_STATE_1 1
|
||||
-#define POWER_STATE_2 2
|
||||
-#define POWER_STATE_3 3
|
||||
#define DOWNLOAD_SAVE_ACTIVATE 0x05
|
||||
#define DOWNLOAD_SAVE_DEFER_ACTIVATE 0x0E
|
||||
#define ACTIVATE_DEFERRED_MICROCODE 0x0F
|
||||
@@ -1229,64 +1220,6 @@ static void nvme_trans_fill_read_cap(u8 *response, struct nvme_id_ns *id_ns,
|
||||
|
||||
/* Start Stop Unit Helper Functions */
|
||||
|
||||
-static int nvme_trans_power_state(struct nvme_ns *ns, struct sg_io_hdr *hdr,
|
||||
- u8 pc, u8 pcmod, u8 start)
|
||||
-{
|
||||
- int res;
|
||||
- int nvme_sc;
|
||||
- struct nvme_id_ctrl *id_ctrl;
|
||||
- int lowest_pow_st; /* max npss = lowest power consumption */
|
||||
- unsigned ps_desired = 0;
|
||||
-
|
||||
- nvme_sc = nvme_identify_ctrl(ns->ctrl, &id_ctrl);
|
||||
- res = nvme_trans_status_code(hdr, nvme_sc);
|
||||
- if (res)
|
||||
- return res;
|
||||
-
|
||||
- lowest_pow_st = max(POWER_STATE_0, (int)(id_ctrl->npss - 1));
|
||||
- kfree(id_ctrl);
|
||||
-
|
||||
- switch (pc) {
|
||||
- case NVME_POWER_STATE_START_VALID:
|
||||
- /* Action unspecified if POWER CONDITION MODIFIER != 0 */
|
||||
- if (pcmod == 0 && start == 0x1)
|
||||
- ps_desired = POWER_STATE_0;
|
||||
- if (pcmod == 0 && start == 0x0)
|
||||
- ps_desired = lowest_pow_st;
|
||||
- break;
|
||||
- case NVME_POWER_STATE_ACTIVE:
|
||||
- /* Action unspecified if POWER CONDITION MODIFIER != 0 */
|
||||
- if (pcmod == 0)
|
||||
- ps_desired = POWER_STATE_0;
|
||||
- break;
|
||||
- case NVME_POWER_STATE_IDLE:
|
||||
- /* Action unspecified if POWER CONDITION MODIFIER != [0,1,2] */
|
||||
- if (pcmod == 0x0)
|
||||
- ps_desired = POWER_STATE_1;
|
||||
- else if (pcmod == 0x1)
|
||||
- ps_desired = POWER_STATE_2;
|
||||
- else if (pcmod == 0x2)
|
||||
- ps_desired = POWER_STATE_3;
|
||||
- break;
|
||||
- case NVME_POWER_STATE_STANDBY:
|
||||
- /* Action unspecified if POWER CONDITION MODIFIER != [0,1] */
|
||||
- if (pcmod == 0x0)
|
||||
- ps_desired = max(POWER_STATE_0, (lowest_pow_st - 2));
|
||||
- else if (pcmod == 0x1)
|
||||
- ps_desired = max(POWER_STATE_0, (lowest_pow_st - 1));
|
||||
- break;
|
||||
- case NVME_POWER_STATE_LU_CONTROL:
|
||||
- default:
|
||||
- res = nvme_trans_completion(hdr, SAM_STAT_CHECK_CONDITION,
|
||||
- ILLEGAL_REQUEST, SCSI_ASC_INVALID_CDB,
|
||||
- SCSI_ASCQ_CAUSE_NOT_REPORTABLE);
|
||||
- break;
|
||||
- }
|
||||
- nvme_sc = nvme_set_features(ns->ctrl, NVME_FEAT_POWER_MGMT, ps_desired, 0,
|
||||
- NULL);
|
||||
- return nvme_trans_status_code(hdr, nvme_sc);
|
||||
-}
|
||||
-
|
||||
static int nvme_trans_send_activate_fw_cmd(struct nvme_ns *ns, struct sg_io_hdr *hdr,
|
||||
u8 buffer_id)
|
||||
{
|
||||
@@ -2235,11 +2168,10 @@ static int nvme_trans_synchronize_cache(struct nvme_ns *ns,
|
||||
static int nvme_trans_start_stop(struct nvme_ns *ns, struct sg_io_hdr *hdr,
|
||||
u8 *cmd)
|
||||
{
|
||||
- u8 immed, pcmod, pc, no_flush, start;
|
||||
+ u8 immed, pcmod, no_flush, start;
|
||||
|
||||
immed = cmd[1] & 0x01;
|
||||
pcmod = cmd[3] & 0x0f;
|
||||
- pc = (cmd[4] & 0xf0) >> 4;
|
||||
no_flush = cmd[4] & 0x04;
|
||||
start = cmd[4] & 0x01;
|
||||
|
||||
@@ -2254,8 +2186,8 @@ static int nvme_trans_start_stop(struct nvme_ns *ns, struct sg_io_hdr *hdr,
|
||||
if (res)
|
||||
return res;
|
||||
}
|
||||
- /* Setup the expected power state transition */
|
||||
- return nvme_trans_power_state(ns, hdr, pc, pcmod, start);
|
||||
+
|
||||
+ return 0;
|
||||
}
|
||||
}
|
||||
|
||||
--
|
||||
2.7.4
|
||||
@@ -0,0 +1,107 @@
|
||||
diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
|
||||
index 2feacc70bf61..b92a7f767bfc 100644
|
||||
--- a/drivers/nvme/host/core.c
|
||||
+++ b/drivers/nvme/host/core.c
|
||||
@@ -597,7 +597,7 @@ int nvme_identify_ns(struct nvme_ctrl *dev, unsigned nsid,
|
||||
}
|
||||
|
||||
int nvme_get_features(struct nvme_ctrl *dev, unsigned fid, unsigned nsid,
|
||||
- dma_addr_t dma_addr, u32 *result)
|
||||
+ void *buffer, size_t buflen, u32 *result)
|
||||
{
|
||||
struct nvme_command c;
|
||||
struct nvme_completion cqe;
|
||||
@@ -606,10 +606,9 @@ int nvme_get_features(struct nvme_ctrl *dev, unsigned fid, unsigned nsid,
|
||||
memset(&c, 0, sizeof(c));
|
||||
c.features.opcode = nvme_admin_get_features;
|
||||
c.features.nsid = cpu_to_le32(nsid);
|
||||
- c.features.dptr.prp1 = cpu_to_le64(dma_addr);
|
||||
c.features.fid = cpu_to_le32(fid);
|
||||
|
||||
- ret = __nvme_submit_sync_cmd(dev->admin_q, &c, &cqe, NULL, 0, 0,
|
||||
+ ret = __nvme_submit_sync_cmd(dev->admin_q, &c, &cqe, buffer, buflen, 0,
|
||||
NVME_QID_ANY, 0, 0);
|
||||
if (ret >= 0 && result)
|
||||
*result = le32_to_cpu(cqe.result);
|
||||
@@ -617,7 +616,7 @@ int nvme_get_features(struct nvme_ctrl *dev, unsigned fid, unsigned nsid,
|
||||
}
|
||||
|
||||
int nvme_set_features(struct nvme_ctrl *dev, unsigned fid, unsigned dword11,
|
||||
- dma_addr_t dma_addr, u32 *result)
|
||||
+ void *buffer, size_t buflen, u32 *result)
|
||||
{
|
||||
struct nvme_command c;
|
||||
struct nvme_completion cqe;
|
||||
@@ -625,12 +624,11 @@ int nvme_set_features(struct nvme_ctrl *dev, unsigned fid, unsigned dword11,
|
||||
|
||||
memset(&c, 0, sizeof(c));
|
||||
c.features.opcode = nvme_admin_set_features;
|
||||
- c.features.dptr.prp1 = cpu_to_le64(dma_addr);
|
||||
c.features.fid = cpu_to_le32(fid);
|
||||
c.features.dword11 = cpu_to_le32(dword11);
|
||||
|
||||
- ret = __nvme_submit_sync_cmd(dev->admin_q, &c, &cqe, NULL, 0, 0,
|
||||
- NVME_QID_ANY, 0, 0);
|
||||
+ ret = __nvme_submit_sync_cmd(dev->admin_q, &c, &cqe,
|
||||
+ buffer, buflen, 0, NVME_QID_ANY, 0, 0);
|
||||
if (ret >= 0 && result)
|
||||
*result = le32_to_cpu(cqe.result);
|
||||
return ret;
|
||||
@@ -664,7 +662,7 @@ int nvme_set_queue_count(struct nvme_ctrl *ctrl, int *count)
|
||||
u32 result;
|
||||
int status, nr_io_queues;
|
||||
|
||||
- status = nvme_set_features(ctrl, NVME_FEAT_NUM_QUEUES, q_count, 0,
|
||||
+ status = nvme_set_features(ctrl, NVME_FEAT_NUM_QUEUES, q_count, NULL, 0,
|
||||
&result);
|
||||
if (status < 0)
|
||||
return status;
|
||||
diff --git a/drivers/nvme/host/nvme.h b/drivers/nvme/host/nvme.h
|
||||
index ab18b78102bf..c2151761ec5f 100644
|
||||
--- a/drivers/nvme/host/nvme.h
|
||||
+++ b/drivers/nvme/host/nvme.h
|
||||
@@ -292,9 +292,9 @@ int nvme_identify_ns(struct nvme_ctrl *dev, unsigned nsid,
|
||||
struct nvme_id_ns **id);
|
||||
int nvme_get_log_page(struct nvme_ctrl *dev, struct nvme_smart_log **log);
|
||||
int nvme_get_features(struct nvme_ctrl *dev, unsigned fid, unsigned nsid,
|
||||
- dma_addr_t dma_addr, u32 *result);
|
||||
+ void *buffer, size_t buflen, u32 *result);
|
||||
int nvme_set_features(struct nvme_ctrl *dev, unsigned fid, unsigned dword11,
|
||||
- dma_addr_t dma_addr, u32 *result);
|
||||
+ void *buffer, size_t buflen, u32 *result);
|
||||
int nvme_set_queue_count(struct nvme_ctrl *ctrl, int *count);
|
||||
void nvme_start_keep_alive(struct nvme_ctrl *ctrl);
|
||||
void nvme_stop_keep_alive(struct nvme_ctrl *ctrl);
|
||||
diff --git a/drivers/nvme/host/scsi.c b/drivers/nvme/host/scsi.c
|
||||
index 44009105f8c8..c2a0a1c7d05d 100644
|
||||
--- a/drivers/nvme/host/scsi.c
|
||||
+++ b/drivers/nvme/host/scsi.c
|
||||
@@ -906,7 +906,7 @@ static int nvme_trans_log_temperature(struct nvme_ns *ns, struct sg_io_hdr *hdr,
|
||||
kfree(smart_log);
|
||||
|
||||
/* Get Features for Temp Threshold */
|
||||
- res = nvme_get_features(ns->ctrl, NVME_FEAT_TEMP_THRESH, 0, 0,
|
||||
+ res = nvme_get_features(ns->ctrl, NVME_FEAT_TEMP_THRESH, 0, NULL, 0,
|
||||
&feature_resp);
|
||||
if (res != NVME_SC_SUCCESS)
|
||||
temp_c_thresh = LOG_TEMP_UNKNOWN;
|
||||
@@ -1039,7 +1039,7 @@ static int nvme_trans_fill_caching_page(struct nvme_ns *ns,
|
||||
if (len < MODE_PAGE_CACHING_LEN)
|
||||
return -EINVAL;
|
||||
|
||||
- nvme_sc = nvme_get_features(ns->ctrl, NVME_FEAT_VOLATILE_WC, 0, 0,
|
||||
+ nvme_sc = nvme_get_features(ns->ctrl, NVME_FEAT_VOLATILE_WC, 0, NULL, 0,
|
||||
&feature_resp);
|
||||
res = nvme_trans_status_code(hdr, nvme_sc);
|
||||
if (res)
|
||||
@@ -1328,7 +1328,7 @@ static int nvme_trans_modesel_get_mp(struct nvme_ns *ns, struct sg_io_hdr *hdr,
|
||||
case MODE_PAGE_CACHING:
|
||||
dword11 = ((mode_page[2] & CACHING_MODE_PAGE_WCE_MASK) ? 1 : 0);
|
||||
nvme_sc = nvme_set_features(ns->ctrl, NVME_FEAT_VOLATILE_WC,
|
||||
- dword11, 0, NULL);
|
||||
+ dword11, NULL, 0, NULL);
|
||||
res = nvme_trans_status_code(hdr, nvme_sc);
|
||||
break;
|
||||
case MODE_PAGE_CONTROL:
|
||||
--
|
||||
2.7.4
|
||||
@@ -0,0 +1,264 @@
|
||||
diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c
|
||||
index b92a7f767bfc..a143c72c3d0d 100644
|
||||
--- a/drivers/nvme/host/core.c
|
||||
+++ b/drivers/nvme/host/core.c
|
||||
@@ -56,6 +56,11 @@ EXPORT_SYMBOL_GPL(nvme_max_retries);
|
||||
static int nvme_char_major;
|
||||
module_param(nvme_char_major, int, 0);
|
||||
|
||||
+static unsigned long default_ps_max_latency_us = 25000;
|
||||
+module_param(default_ps_max_latency_us, ulong, 0644);
|
||||
+MODULE_PARM_DESC(ps_max_latency_us,
|
||||
+ "default max power saving latency; overridden per device in sysfs");
|
||||
+
|
||||
static LIST_HEAD(nvme_ctrl_list);
|
||||
static DEFINE_SPINLOCK(dev_list_lock);
|
||||
|
||||
@@ -1205,6 +1210,98 @@ static void nvme_set_queue_limits(struct nvme_ctrl *ctrl,
|
||||
blk_queue_write_cache(q, vwc, vwc);
|
||||
}
|
||||
|
||||
+static void nvme_configure_apst(struct nvme_ctrl *ctrl)
|
||||
+{
|
||||
+ /*
|
||||
+ * APST (Autonomous Power State Transition) lets us program a
|
||||
+ * table of power state transitions that the controller will
|
||||
+ * perform automatically. We configure it with a simple
|
||||
+ * heuristic: we are willing to spend at most 2% of the time
|
||||
+ * transitioning between power states. Therefore, when running
|
||||
+ * in any given state, we will enter the next lower-power
|
||||
+ * non-operational state after waiting 100 * (enlat + exlat)
|
||||
+ * microseconds, as long as that state's total latency is under
|
||||
+ * the requested maximum latency.
|
||||
+ *
|
||||
+ * We will not autonomously enter any non-operational state for
|
||||
+ * which the total latency exceeds ps_max_latency_us. Users
|
||||
+ * can set ps_max_latency_us to zero to turn off APST.
|
||||
+ */
|
||||
+
|
||||
+ unsigned apste;
|
||||
+ struct nvme_feat_auto_pst *table;
|
||||
+ int ret;
|
||||
+
|
||||
+ if (!ctrl->apsta)
|
||||
+ return; /* APST isn't supported. */
|
||||
+
|
||||
+ if (ctrl->npss > 31) {
|
||||
+ dev_warn(ctrl->device, "NPSS is invalid; not using APST\n");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
+ table = kzalloc(sizeof(*table), GFP_KERNEL);
|
||||
+ if (!table)
|
||||
+ return;
|
||||
+
|
||||
+ if (ctrl->ps_max_latency_us == 0) {
|
||||
+ /* Turn off APST. */
|
||||
+ apste = 0;
|
||||
+ } else {
|
||||
+ __le64 target = cpu_to_le64(0);
|
||||
+ int state;
|
||||
+
|
||||
+ /*
|
||||
+ * Walk through all states from lowest- to highest-power.
|
||||
+ * According to the spec, lower-numbered states use more
|
||||
+ * power. NPSS, despite the name, is the index of the
|
||||
+ * lowest-power state, not the number of states.
|
||||
+ */
|
||||
+ for (state = (int)ctrl->npss; state >= 0; state--) {
|
||||
+ u64 total_latency_us, transition_ms;
|
||||
+
|
||||
+ if (target)
|
||||
+ table->entries[state] = target;
|
||||
+
|
||||
+ /*
|
||||
+ * Is this state a useful non-operational state for
|
||||
+ * higher-power states to autonomously transition to?
|
||||
+ */
|
||||
+ if (!(ctrl->psd[state].flags & 2))
|
||||
+ continue; /* It's an operational state. */
|
||||
+
|
||||
+ total_latency_us =
|
||||
+ (u64)cpu_to_le32(ctrl->psd[state].entry_lat) +
|
||||
+ + cpu_to_le32(ctrl->psd[state].exit_lat);
|
||||
+ if (total_latency_us > ctrl->ps_max_latency_us)
|
||||
+ continue;
|
||||
+
|
||||
+ /*
|
||||
+ * This state is good. Use it as the APST idle
|
||||
+ * target for higher power states.
|
||||
+ */
|
||||
+ transition_ms = total_latency_us + 19;
|
||||
+ do_div(transition_ms, 20);
|
||||
+ if (transition_ms >= (1 << 24))
|
||||
+ transition_ms = (1 << 24);
|
||||
+
|
||||
+ target = cpu_to_le64((state << 3) |
|
||||
+ (transition_ms << 8));
|
||||
+ }
|
||||
+
|
||||
+ apste = 1;
|
||||
+ }
|
||||
+
|
||||
+ ret = nvme_set_features(ctrl, NVME_FEAT_AUTO_PST, apste,
|
||||
+ table, sizeof(*table), NULL);
|
||||
+ if (ret)
|
||||
+ dev_err(ctrl->device, "failed to set APST feature (%d)\n", ret);
|
||||
+
|
||||
+ kfree(table);
|
||||
+}
|
||||
+
|
||||
+static struct attribute_group nvme_dev_dynamic_attrs_group;
|
||||
+
|
||||
/*
|
||||
* Initialize the cached copies of the Identify data and various controller
|
||||
* register in our nvme_ctrl structure. This should be called as soon as
|
||||
@@ -1271,6 +1368,10 @@ int nvme_init_identify(struct nvme_ctrl *ctrl)
|
||||
ctrl->sgls = le32_to_cpu(id->sgls);
|
||||
ctrl->kas = le16_to_cpu(id->kas);
|
||||
|
||||
+ ctrl->npss = id->npss;
|
||||
+ ctrl->apsta = id->apsta;
|
||||
+ memcpy(ctrl->psd, id->psd, sizeof(ctrl->psd));
|
||||
+
|
||||
if (ctrl->ops->is_fabrics) {
|
||||
ctrl->icdoff = le16_to_cpu(id->icdoff);
|
||||
ctrl->ioccsz = le32_to_cpu(id->ioccsz);
|
||||
@@ -1294,6 +1395,10 @@ int nvme_init_identify(struct nvme_ctrl *ctrl)
|
||||
}
|
||||
|
||||
kfree(id);
|
||||
+
|
||||
+ nvme_configure_apst(ctrl);
|
||||
+
|
||||
+ sysfs_update_group(&ctrl->device->kobj, &nvme_dev_dynamic_attrs_group);
|
||||
return ret;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(nvme_init_identify);
|
||||
@@ -1564,6 +1669,41 @@ static ssize_t nvme_sysfs_show_address(struct device *dev,
|
||||
}
|
||||
static DEVICE_ATTR(address, S_IRUGO, nvme_sysfs_show_address, NULL);
|
||||
|
||||
+static ssize_t nvme_sysfs_show_ps_max_latency_us(
|
||||
+ struct device *dev,
|
||||
+ struct device_attribute *attr,
|
||||
+ char *buf)
|
||||
+{
|
||||
+ struct nvme_ctrl *ctrl = dev_get_drvdata(dev);
|
||||
+
|
||||
+ return snprintf(buf, PAGE_SIZE, "%llu\n", ctrl->ps_max_latency_us);
|
||||
+}
|
||||
+
|
||||
+static ssize_t nvme_sysfs_store_ps_max_latency_us(
|
||||
+ struct device *dev,
|
||||
+ struct device_attribute *attr,
|
||||
+ const char *buf, size_t size)
|
||||
+{
|
||||
+ struct nvme_ctrl *ctrl = dev_get_drvdata(dev);
|
||||
+ int ret;
|
||||
+ u64 val;
|
||||
+
|
||||
+ ret = kstrtoull(buf, 10, &val);
|
||||
+ if (ret)
|
||||
+ return ret;
|
||||
+
|
||||
+ if (ctrl->ps_max_latency_us != val) {
|
||||
+ ctrl->ps_max_latency_us = val;
|
||||
+ nvme_configure_apst(ctrl);
|
||||
+ }
|
||||
+
|
||||
+ return size;
|
||||
+}
|
||||
+
|
||||
+static DEVICE_ATTR(ps_max_latency_us, 0644,
|
||||
+ nvme_sysfs_show_ps_max_latency_us,
|
||||
+ nvme_sysfs_store_ps_max_latency_us);
|
||||
+
|
||||
static struct attribute *nvme_dev_attrs[] = {
|
||||
&dev_attr_reset_controller.attr,
|
||||
&dev_attr_rescan_controller.attr,
|
||||
@@ -1605,8 +1745,33 @@ static struct attribute_group nvme_dev_attrs_group = {
|
||||
.is_visible = nvme_dev_attrs_are_visible,
|
||||
};
|
||||
|
||||
+static struct attribute *nvme_dev_dynamic_attrs[] = {
|
||||
+ &dev_attr_ps_max_latency_us.attr,
|
||||
+ NULL
|
||||
+};
|
||||
+
|
||||
+static umode_t nvme_dev_dynamic_attrs_are_visible(struct kobject *kobj,
|
||||
+ struct attribute *a, int n)
|
||||
+{
|
||||
+ struct device *dev = container_of(kobj, struct device, kobj);
|
||||
+ struct nvme_ctrl *ctrl = dev_get_drvdata(dev);
|
||||
+
|
||||
+ if (a == &dev_attr_ps_max_latency_us.attr) {
|
||||
+ if (!ctrl->apsta)
|
||||
+ return 0;
|
||||
+ }
|
||||
+
|
||||
+ return a->mode;
|
||||
+}
|
||||
+
|
||||
+static struct attribute_group nvme_dev_dynamic_attrs_group = {
|
||||
+ .attrs = nvme_dev_dynamic_attrs,
|
||||
+ .is_visible = nvme_dev_dynamic_attrs_are_visible,
|
||||
+};
|
||||
+
|
||||
static const struct attribute_group *nvme_dev_attr_groups[] = {
|
||||
&nvme_dev_attrs_group,
|
||||
+ &nvme_dev_dynamic_attrs_group,
|
||||
NULL,
|
||||
};
|
||||
|
||||
@@ -1991,6 +2156,7 @@ int nvme_init_ctrl(struct nvme_ctrl *ctrl, struct device *dev,
|
||||
ctrl->quirks = quirks;
|
||||
INIT_WORK(&ctrl->scan_work, nvme_scan_work);
|
||||
INIT_WORK(&ctrl->async_event_work, nvme_async_event_work);
|
||||
+ ctrl->ps_max_latency_us = default_ps_max_latency_us;
|
||||
|
||||
ret = nvme_set_instance(ctrl);
|
||||
if (ret)
|
||||
diff --git a/drivers/nvme/host/nvme.h b/drivers/nvme/host/nvme.h
|
||||
index c2151761ec5f..16d51006afc0 100644
|
||||
--- a/drivers/nvme/host/nvme.h
|
||||
+++ b/drivers/nvme/host/nvme.h
|
||||
@@ -129,13 +129,19 @@ struct nvme_ctrl {
|
||||
u32 vs;
|
||||
u32 sgls;
|
||||
u16 kas;
|
||||
+ u8 npss;
|
||||
+ u8 apsta;
|
||||
unsigned int kato;
|
||||
bool subsystem;
|
||||
unsigned long quirks;
|
||||
+ struct nvme_id_power_state psd[32];
|
||||
struct work_struct scan_work;
|
||||
struct work_struct async_event_work;
|
||||
struct delayed_work ka_work;
|
||||
|
||||
+ /* Power saving configuration */
|
||||
+ u64 ps_max_latency_us;
|
||||
+
|
||||
/* Fabrics only */
|
||||
u16 sqsize;
|
||||
u32 ioccsz;
|
||||
diff --git a/include/linux/nvme.h b/include/linux/nvme.h
|
||||
index d8b37bab2887..a76237dac4b0 100644
|
||||
--- a/include/linux/nvme.h
|
||||
+++ b/include/linux/nvme.h
|
||||
@@ -543,6 +543,12 @@ struct nvme_dsm_range {
|
||||
__le64 slba;
|
||||
};
|
||||
|
||||
+/* Features */
|
||||
+
|
||||
+struct nvme_feat_auto_pst {
|
||||
+ __le64 entries[32];
|
||||
+};
|
||||
+
|
||||
/* Admin commands */
|
||||
|
||||
enum nvme_admin_opcode {
|
||||
--
|
||||
2.7.4
|
||||
@@ -41,11 +41,19 @@ Revert-cpufreq-pcc-Enable-autoload-of-pcc-cpufreq-fo.patch
|
||||
# breaks nvidia304
|
||||
Revert-x86-mm-mtrr-Remove-kernel-internal-MTRR-inter.patch
|
||||
|
||||
# fix non-booting systems
|
||||
x86-smpboot-Init-apic-mapping-before-usage.patch
|
||||
|
||||
###
|
||||
### Core
|
||||
###
|
||||
base-cacheinfo-silence-DT-warnings.patch
|
||||
|
||||
# Patch for having the cpupower setting the governor
|
||||
# (from https://bugzilla.kernel.org/show_bug.cgi?id=135391, same as
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1374212)
|
||||
kernel-governor-cpupower-Correct-return-type-of-cpu_power_is_cpu_onl.patch
|
||||
|
||||
###
|
||||
### i2c
|
||||
###
|
||||
@@ -119,8 +127,20 @@ ata-prefer-ata-drivers-over-ide-drivers-when-both-are-built.patch
|
||||
# Nice SSD speedup
|
||||
block-Make-CFQ-default-to-IOPS-mode-on-SSDs.patch
|
||||
|
||||
# ahci ids
|
||||
ahci-add-new-Intel-device-IDs.patch
|
||||
# Include new BFQ I/O scheduler
|
||||
# (See http://algo.ing.unimo.it/people/paolo/disk_sched)
|
||||
#
|
||||
# Release of BFQ I/O scheduler v8r4 (rediffed from git https://github.com/linusw/linux-bfq)
|
||||
linux-BFQ-v8r4.patch
|
||||
|
||||
# Let NVME drives enter in power state
|
||||
# (see https://github.com/damige/linux-nvme/tree/master/src)
|
||||
nvmepatch1-V4.patch
|
||||
nvmepatch2-V4.patch
|
||||
nvmepatch3-V4.patch
|
||||
|
||||
# fix feature check, reported on dev@ ml
|
||||
dm-raid-fix-compat_features-validation.patch
|
||||
|
||||
###
|
||||
### Char
|
||||
@@ -134,9 +154,8 @@ Revert-ipmi-Start-the-timer-and-thread-on-internal-m.patch
|
||||
###
|
||||
|
||||
# aufs from: http://aufs.sourceforge.net/ (mga#8314)
|
||||
fs-aufs-4.7.patch
|
||||
fs-aufs-4.7-modular.patch
|
||||
fs-aufs-4.7-ver-fix.patch
|
||||
fs-aufs-4.8.patch
|
||||
fs-aufs-4.8-modular.patch
|
||||
|
||||
###
|
||||
### FireWire
|
||||
@@ -171,6 +190,14 @@ gpu-drm-mach64-linux-3.14-buildfix.patch
|
||||
gpu-drm-mach64-3.17-buildfix.patch
|
||||
gpu-drm-mach64-3.18-buildfix.patch
|
||||
|
||||
# Attempt to fix FIFO underrun problems:
|
||||
# (from https://patchwork.freedesktop.org/patch/113642/ and
|
||||
# also from https://bugs.freedesktop.org/attachment.cgi?id=127264, first reference from
|
||||
# https://bugs.freedesktop.org/show_bug.cgi?id=97450). Does not completely resolve the
|
||||
# issues but reduce.
|
||||
# now in drm-next: https://cgit.freedesktop.org/~airlied/linux/commit?h=drm-next&id=5a920b85f2c6e3fd7d9dd9bb3f3345e9085e2360
|
||||
gpu-drm-i915-gen9-fix-DDB-partitioning-for-multi-screen-cases.patch
|
||||
|
||||
###
|
||||
### Hardware Monitoring
|
||||
###
|
||||
@@ -222,6 +249,12 @@ net-netfilter-psd.patch
|
||||
net-netfilter-psd-mdv.patch
|
||||
net-netfilter-psd-2.6.35-buildfix.patch
|
||||
|
||||
# rtlwifi regression
|
||||
net-wireless-rtlwifi-Fix-regression-caused-by-commit-d86e64768859.patch
|
||||
|
||||
# CVE-2016-7039
|
||||
net-add-recursion-limit-to-GRO.patch
|
||||
|
||||
###
|
||||
### Platform drivers
|
||||
###
|
||||
@@ -232,10 +265,6 @@ platform-x86-add-shuttle-wmi-driver.patch
|
||||
platform-x86-shuttle-wmi-drop-devinit-exit.patch
|
||||
platform-x86-shuttle-wmi-4.2-buildfix.patch
|
||||
|
||||
#
|
||||
intel_th-Fix-a-deadlock-in-modprobing.patch
|
||||
intel_th-pci-Add-Kaby-Lake-PCH-H-support.patch
|
||||
|
||||
###
|
||||
### RTC
|
||||
###
|
||||
@@ -331,6 +360,7 @@ video-mageia-logo.patch
|
||||
# add rtl8723bs support (mga#15874)
|
||||
3rd-rtl8723bs.patch
|
||||
3rd-rtl8723bs-4.7-buildfix.patch
|
||||
3rd-rtl8723bs-4.8-buildfix.patch
|
||||
|
||||
###
|
||||
### Security
|
||||
@@ -348,10 +378,6 @@ video-mageia-logo.patch
|
||||
### ARM
|
||||
###
|
||||
|
||||
# RPi2 support
|
||||
# Read MAC address from DT
|
||||
arm-0001-ARM-bcm2835-dt-Add-the-ethernet-to-the-device-trees.patch
|
||||
|
||||
###
|
||||
### IA64
|
||||
###
|
||||
@@ -360,6 +386,11 @@ arm-0001-ARM-bcm2835-dt-Add-the-ethernet-to-the-device-trees.patch
|
||||
### Tools
|
||||
###
|
||||
|
||||
# wipe powerpc refrence so we can nuke dangling symlinks (mga#17676)
|
||||
tools-testing-selftest-Makefile-remove-powerpc-reference.patch
|
||||
|
||||
###
|
||||
### UAPI
|
||||
###
|
||||
# breaks linux-arm build
|
||||
Revert-include-uapi-linux-atm_zatm.h-include-linux-t.patch
|
||||
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
--- linux/tools/testing/selftests/Makefile.orig
|
||||
+++ linux/tools/testing/selftests/Makefile
|
||||
@@ -15,7 +15,6 @@ TARGETS += memory-hotplug
|
||||
TARGETS += mount
|
||||
TARGETS += mqueue
|
||||
TARGETS += net
|
||||
-TARGETS += powerpc
|
||||
TARGETS += pstore
|
||||
TARGETS += ptrace
|
||||
TARGETS += seccomp
|
||||
+61
@@ -0,0 +1,61 @@
|
||||
From 1e90a13d0c3dc94512af1ccb2b6563e8297838fa Mon Sep 17 00:00:00 2001
|
||||
From: Thomas Gleixner <tglx@linutronix.de>
|
||||
Date: Sat, 29 Oct 2016 13:42:42 +0200
|
||||
Subject: [PATCH] x86/smpboot: Init apic mapping before usage
|
||||
|
||||
The recent changes, which forced the registration of the boot cpu on UP
|
||||
systems, which do not have ACPI tables, have been fixed for systems w/o
|
||||
local APIC, but left a wreckage for systems which have neither ACPI nor
|
||||
mptables, but the CPU has an APIC, e.g. virtualbox.
|
||||
|
||||
The boot process crashes in prefill_possible_map() as it wants to register
|
||||
the boot cpu, which needs to access the local apic, but the local APIC is
|
||||
not yet mapped.
|
||||
|
||||
There is no reason why init_apic_mapping() can't be invoked before
|
||||
prefill_possible_map(). So instead of playing another silly early mapping
|
||||
game, as the ACPI/mptables code does, we just move init_apic_mapping()
|
||||
before the call to prefill_possible_map().
|
||||
|
||||
In hindsight, I should have noticed that combination earlier.
|
||||
|
||||
Sorry for the churn (also in stable)!
|
||||
|
||||
Fixes: ff8560512b8d ("x86/boot/smp: Don't try to poke disabled/non-existent APIC")
|
||||
Reported-and-debugged-by: Michal Necasek <michal.necasek@oracle.com>
|
||||
Reported-and-tested-by: Wolfgang Bauer <wbauer@tmo.at>
|
||||
Cc: prarit@redhat.com
|
||||
Cc: ville.syrjala@linux.intel.com
|
||||
Cc: michael.thayer@oracle.com
|
||||
Cc: knut.osmundsen@oracle.com
|
||||
Cc: frank.mehnert@oracle.com
|
||||
Cc: Borislav Petkov <bp@alien8.de>
|
||||
Cc: stable@vger.kernel.org
|
||||
Link: http://lkml.kernel.org/r/alpine.DEB.2.20.1610282114380.5053@nanos
|
||||
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
|
||||
---
|
||||
arch/x86/kernel/setup.c | 7 ++++++-
|
||||
1 file changed, 6 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
|
||||
index bbfbca5..9c337b0 100644
|
||||
--- a/arch/x86/kernel/setup.c
|
||||
+++ b/arch/x86/kernel/setup.c
|
||||
@@ -1222,11 +1222,16 @@ void __init setup_arch(char **cmdline_p)
|
||||
if (smp_found_config)
|
||||
get_smp_config();
|
||||
|
||||
+ /*
|
||||
+ * Systems w/o ACPI and mptables might not have it mapped the local
|
||||
+ * APIC yet, but prefill_possible_map() might need to access it.
|
||||
+ */
|
||||
+ init_apic_mappings();
|
||||
+
|
||||
prefill_possible_map();
|
||||
|
||||
init_cpu_to_node();
|
||||
|
||||
- init_apic_mappings();
|
||||
io_apic_init_mappings();
|
||||
|
||||
kvm_guest_init();
|
||||
@@ -12,14 +12,14 @@
|
||||
<IsA>app:console</IsA>
|
||||
<Summary>CPU power management tools</Summary>
|
||||
<Description>cpupowertools contains utilities to manage power management and frequency scaling policies of modern CPUs.</Description>
|
||||
<Archive sha1sum="36922e152e9268a68070577c613da502a6c3d577" type="targz">https://www.kernel.org/pub/linux/kernel/v4.x/linux-4.7.tar.gz</Archive>
|
||||
<Archive sha1sum="a85e6ca968b10ec0eace2daaaa59fc8734d0db74" type="targz">https://www.kernel.org/pub/linux/kernel/v4.x/linux-4.8.tar.gz</Archive>
|
||||
<BuildDependencies>
|
||||
<Dependency>pciutils-devel</Dependency>
|
||||
</BuildDependencies>
|
||||
<Patches>
|
||||
<!-- Linux patches -->
|
||||
<Patch level="1" compressionType="xz">patches/linux/patch-4.7.2.xz</Patch>
|
||||
<!-- Mageia Linux patches // compatible with http://svnweb.mageia.org/packages/cauldron/kernel/releases/4.7.2/2.mga6/PATCHES/patches/series-->
|
||||
<Patches>
|
||||
<!-- Linux patches -->
|
||||
<Patch level="1" compressionType="xz">patches/linux/patch-4.8.6.xz</Patch>
|
||||
<!-- Mageia Linux patches // compatible with http://svnweb.mageia.org/packages/cauldron/kernel/releases/4.8.6/1.mga6/PATCHES/patches/series-->
|
||||
<!--stable patches-->
|
||||
<!--other patches-->
|
||||
<Patch level="1">patches/mageia/Revert-ipmi-Start-the-timer-and-thread-on-internal-m.patch</Patch>
|
||||
@@ -27,9 +27,11 @@
|
||||
<Patch level="1">patches/mageia/x86-boot-video-80x25-if-break.patch</Patch>
|
||||
<Patch level="1">patches/mageia/x86-default_poweroff_up_machines.patch</Patch>
|
||||
<Patch level="1">patches/mageia/x86-increase-default-minimum-vmalloc-area-by-64MB-to-192MB.patch</Patch>
|
||||
<Patch level="1">patches/mageia/Revert-cpufreq-pcc-Enable-autoload-of-pcc-cpufreq-fo.patch</Patch>
|
||||
<Patch level="1">patches/mageia/Revert-cpufreq-pcc-Enable-autoload-of-pcc-cpufreq-fo.patch</Patch>
|
||||
<Patch level="1">patches/mageia/x86-smpboot-Init-apic-mapping-before-usage.patch</Patch>
|
||||
<Patch level="1">patches/mageia/Revert-x86-mm-mtrr-Remove-kernel-internal-MTRR-inter.patch</Patch>
|
||||
<Patch level="1">patches/mageia/base-cacheinfo-silence-DT-warnings.patch</Patch>
|
||||
<Patch level="1">patches/mageia/kernel-governor-cpupower-Correct-return-type-of-cpu_power_is_cpu_onl.patch</Patch>
|
||||
<Patch level="1">patches/mageia/pci-add-ALI-M5229-ide-compatibility-mode-quirk.patch</Patch>
|
||||
<Patch level="1">patches/mageia/pci-quirks-drop-devinit-exit.patch</Patch>
|
||||
<Patch level="1">patches/mageia/acpi-CLEVO-M360S-disable_acpi_irq.patch</Patch>
|
||||
@@ -48,9 +50,13 @@
|
||||
<Patch level="1">patches/mageia/block-floppy-disable-pnp-modalias.patch</Patch>
|
||||
<Patch level="1">patches/mageia/ata-prefer-ata-drivers-over-ide-drivers-when-both-are-built.patch</Patch>
|
||||
<Patch level="1">patches/mageia/block-Make-CFQ-default-to-IOPS-mode-on-SSDs.patch</Patch>
|
||||
<Patch level="1">patches/mageia/fs-aufs-4.7.patch</Patch>
|
||||
<Patch level="1">patches/mageia/fs-aufs-4.7-modular.patch</Patch>
|
||||
<Patch level="1">patches/mageia/fs-aufs-4.7-ver-fix.patch</Patch>
|
||||
<Patch level="1">patches/mageia/linux-BFQ-v8r4.patch</Patch>
|
||||
<Patch level="1">patches/mageia/nvmepatch1-V4.patch</Patch>
|
||||
<Patch level="1">patches/mageia/nvmepatch2-V4.patch</Patch>
|
||||
<Patch level="1">patches/mageia/nvmepatch3-V4.patch</Patch>
|
||||
<Patch level="1">patches/mageia/dm-raid-fix-compat_features-validation.patch</Patch>
|
||||
<Patch level="1">patches/mageia/fs-aufs-4.8.patch</Patch>
|
||||
<Patch level="1">patches/mageia/fs-aufs-4.8-modular.patch</Patch>
|
||||
<Patch level="1">patches/mageia/firewire-ieee1394-module-aliases.patch</Patch>
|
||||
<Patch level="1">patches/mageia/char-agp-intel-new-Q57-id.patch</Patch>
|
||||
<!--remove external mach64 support for buildfix-->
|
||||
@@ -71,6 +77,7 @@
|
||||
<Patch level="1">patches/mageia/gpu-drm-mach64-linux-3.14-buildfix.patch</Patch>
|
||||
<Patch level="1">patches/mageia/gpu-drm-mach64-3.17-buildfix.patch</Patch>
|
||||
<Patch level="1">patches/mageia/gpu-drm-mach64-3.18-buildfix.patch</Patch--><!--1-->
|
||||
<Patch level="1">patches/mageia/gpu-drm-i915-gen9-fix-DDB-partitioning-for-multi-screen-cases.patch</Patch>
|
||||
<Patch level="1">patches/mageia/input-i8042-quirks-for-Fujitsu-Lifebook-A544-and-Lif.patch</Patch>
|
||||
<Patch level="1">patches/mageia/net-sis190-fix-list-usage.patch</Patch>
|
||||
<Patch level="1">patches/mageia/net-netfilter-IFWLOG.patch</Patch>
|
||||
@@ -83,11 +90,11 @@
|
||||
<Patch level="1">patches/mageia/net-netfilter-psd.patch</Patch>
|
||||
<Patch level="1">patches/mageia/net-netfilter-psd-mdv.patch</Patch>
|
||||
<Patch level="1">patches/mageia/net-netfilter-psd-2.6.35-buildfix.patch</Patch>
|
||||
<Patch level="1">patches/mageia/net-wireless-rtlwifi-Fix-regression-caused-by-commit-d86e64768859.patch</Patch>
|
||||
<Patch level="1">patches/mageia/net-add-recursion-limit-to-GRO.patch</Patch>
|
||||
<Patch level="1">patches/mageia/platform-x86-add-shuttle-wmi-driver.patch</Patch>
|
||||
<Patch level="1">patches/mageia/platform-x86-shuttle-wmi-drop-devinit-exit.patch</Patch>
|
||||
<Patch level="1">patches/mageia/platform-x86-shuttle-wmi-4.2-buildfix.patch</Patch>
|
||||
<Patch level="1">patches/mageia/intel_th-Fix-a-deadlock-in-modprobing.patch</Patch>
|
||||
<Patch level="1">patches/mageia/intel_th-pci-Add-Kaby-Lake-PCH-H-support.patch</Patch>
|
||||
<Patch level="1">patches/mageia/include-kbuild-export-pci_ids.patch</Patch>
|
||||
<Patch level="1">patches/mageia/hid-usbhid-IBM-BladeCenterHS20-quirk.patch</Patch>
|
||||
<Patch level="1">patches/mageia/usb-storage-unusual_devs-add-id.patch</Patch>
|
||||
@@ -120,9 +127,10 @@
|
||||
<Patch level="1">patches/mageia/3rd-viahss-3.0-buildfix.patch</Patch>
|
||||
<Patch level="1">patches/mageia/3rd-rtl8723bs.patch</Patch>
|
||||
<Patch level="1">patches/mageia/3rd-rtl8723bs-4.7-buildfix.patch</Patch>
|
||||
<Patch level="1">patches/mageia/ahci-add-new-Intel-device-IDs.patch</Patch>
|
||||
<Patch level="1">patches/mageia/arm-0001-ARM-bcm2835-dt-Add-the-ethernet-to-the-device-trees.patch</Patch>
|
||||
</Patches>
|
||||
<Patch level="1">patches/mageia/3rd-rtl8723bs-4.8-buildfix.patch</Patch>
|
||||
<Patch level="1">patches/mageia/tools-testing-selftest-Makefile-remove-powerpc-reference.patch</Patch>
|
||||
<Patch level="1">patches/mageia/Revert-include-uapi-linux-atm_zatm.h-include-linux-t.patch</Patch>
|
||||
</Patches>
|
||||
</Source>
|
||||
|
||||
<Package>
|
||||
|
||||
Reference in New Issue
Block a user