diff options
author | Alexandre Oliva <lxoliva@fsfla.org> | 2015-04-15 17:56:42 +0000 |
---|---|---|
committer | Alexandre Oliva <lxoliva@fsfla.org> | 2015-04-15 17:56:42 +0000 |
commit | 3e424e3de9a5bcd1764624d488d3bef95faa607a (patch) | |
tree | 751d248b30a05eb872fce61308a48ca8063ff417 /freed-ora/current/f20 | |
parent | 243c5f4886b207c0a2927436844586edec3c9852 (diff) | |
download | linux-libre-raptor-3e424e3de9a5bcd1764624d488d3bef95faa607a.tar.gz linux-libre-raptor-3e424e3de9a5bcd1764624d488d3bef95faa607a.zip |
3.19.4-100.fc20.gnu
Diffstat (limited to 'freed-ora/current/f20')
15 files changed, 484 insertions, 599 deletions
diff --git a/freed-ora/current/f20/Input-synaptics-do-not-retrieve-the-board-id-on-old-.patch b/freed-ora/current/f20/Input-synaptics-do-not-retrieve-the-board-id-on-old-.patch deleted file mode 100644 index 51ba54ddc..000000000 --- a/freed-ora/current/f20/Input-synaptics-do-not-retrieve-the-board-id-on-old-.patch +++ /dev/null @@ -1,33 +0,0 @@ -From: Benjamin Tissoires <benjamin.tissoires@redhat.com> -Date: Sun, 8 Mar 2015 22:33:36 -0700 -Subject: [PATCH] Input: synaptics - do not retrieve the board id on old - firmwares - -The board id capability has been added in firmware 7.5. - -Cc: stable@vger.kernel.org -Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> -Acked-by: Hans de Goede <hdegoede@redhat.com> -Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> ---- - drivers/input/mouse/synaptics.c | 4 ++++ - 1 file changed, 4 insertions(+) - -diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c -index 2f42a712f3e0..2176874a41b1 100644 ---- a/drivers/input/mouse/synaptics.c -+++ b/drivers/input/mouse/synaptics.c -@@ -250,6 +250,10 @@ static int synaptics_board_id(struct psmouse *psmouse) - struct synaptics_data *priv = psmouse->private; - unsigned char bid[3]; - -+ /* firmwares prior 7.5 have no board_id encoded */ -+ if (SYN_ID_FULL(priv->identity) < 0x705) -+ return 0; -+ - if (synaptics_send_cmd(psmouse, SYN_QUE_MODES, bid)) - return -1; - priv->board_id = ((bid[0] & 0xfc) << 6) | bid[1]; --- -2.1.0 - diff --git a/freed-ora/current/f20/Input-synaptics-fix-middle-button-on-Lenovo-2015-pro.patch b/freed-ora/current/f20/Input-synaptics-fix-middle-button-on-Lenovo-2015-pro.patch deleted file mode 100644 index 8a677de79..000000000 --- a/freed-ora/current/f20/Input-synaptics-fix-middle-button-on-Lenovo-2015-pro.patch +++ /dev/null @@ -1,100 +0,0 @@ -From: Dmitry Torokhov <dmitry.torokhov@gmail.com> -Date: Sun, 8 Mar 2015 22:30:43 -0700 -Subject: [PATCH] Input: synaptics - fix middle button on Lenovo 2015 products - -On the X1 Carbon 3rd gen (with a 2015 broadwell cpu), the physical middle -button of the trackstick (attached to the touchpad serio device, of course) -seems to get lost. - -Actually, the touchpads reports 3 extra buttons, which falls in the switch -below to the '2' case. Let's handle the case of odd numbers also, so that -the middle button finds its way back. - -Cc: stable@vger.kernel.org -Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> -Acked-by: Hans de Goede <hdegoede@redhat.com> -Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> ---- - drivers/input/mouse/synaptics.c | 44 ++++++++++++++++++++--------------------- - 1 file changed, 21 insertions(+), 23 deletions(-) - -diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c -index 9567a708aa64..e78cc5578527 100644 ---- a/drivers/input/mouse/synaptics.c -+++ b/drivers/input/mouse/synaptics.c -@@ -658,6 +658,18 @@ static void synaptics_parse_agm(const unsigned char buf[], - priv->agm_pending = true; - } - -+static void synaptics_parse_ext_buttons(const unsigned char buf[], -+ struct synaptics_data *priv, -+ struct synaptics_hw_state *hw) -+{ -+ unsigned int ext_bits = -+ (SYN_CAP_MULTI_BUTTON_NO(priv->ext_cap) + 1) >> 1; -+ unsigned int ext_mask = GENMASK(ext_bits - 1, 0); -+ -+ hw->ext_buttons = buf[4] & ext_mask; -+ hw->ext_buttons |= (buf[5] & ext_mask) << ext_bits; -+} -+ - static bool is_forcepad; - - static int synaptics_parse_hw_state(const unsigned char buf[], -@@ -744,28 +756,9 @@ static int synaptics_parse_hw_state(const unsigned char buf[], - hw->down = ((buf[0] ^ buf[3]) & 0x02) ? 1 : 0; - } - -- if (SYN_CAP_MULTI_BUTTON_NO(priv->ext_cap) && -+ if (SYN_CAP_MULTI_BUTTON_NO(priv->ext_cap) > 0 && - ((buf[0] ^ buf[3]) & 0x02)) { -- switch (SYN_CAP_MULTI_BUTTON_NO(priv->ext_cap) & ~0x01) { -- default: -- /* -- * if nExtBtn is greater than 8 it should be -- * considered invalid and treated as 0 -- */ -- break; -- case 8: -- hw->ext_buttons |= ((buf[5] & 0x08)) ? 0x80 : 0; -- hw->ext_buttons |= ((buf[4] & 0x08)) ? 0x40 : 0; -- case 6: -- hw->ext_buttons |= ((buf[5] & 0x04)) ? 0x20 : 0; -- hw->ext_buttons |= ((buf[4] & 0x04)) ? 0x10 : 0; -- case 4: -- hw->ext_buttons |= ((buf[5] & 0x02)) ? 0x08 : 0; -- hw->ext_buttons |= ((buf[4] & 0x02)) ? 0x04 : 0; -- case 2: -- hw->ext_buttons |= ((buf[5] & 0x01)) ? 0x02 : 0; -- hw->ext_buttons |= ((buf[4] & 0x01)) ? 0x01 : 0; -- } -+ synaptics_parse_ext_buttons(buf, priv, hw); - } - } else { - hw->x = (((buf[1] & 0x1f) << 8) | buf[2]); -@@ -832,6 +825,7 @@ static void synaptics_report_buttons(struct psmouse *psmouse, - { - struct input_dev *dev = psmouse->dev; - struct synaptics_data *priv = psmouse->private; -+ int ext_bits = (SYN_CAP_MULTI_BUTTON_NO(priv->ext_cap) + 1) >> 1; - int i; - - input_report_key(dev, BTN_LEFT, hw->left); -@@ -845,8 +839,12 @@ static void synaptics_report_buttons(struct psmouse *psmouse, - input_report_key(dev, BTN_BACK, hw->down); - } - -- for (i = 0; i < SYN_CAP_MULTI_BUTTON_NO(priv->ext_cap); i++) -- input_report_key(dev, BTN_0 + i, hw->ext_buttons & (1 << i)); -+ for (i = 0; i < ext_bits; i++) { -+ input_report_key(dev, BTN_0 + 2 * i, -+ hw->ext_buttons & (1 << i)); -+ input_report_key(dev, BTN_1 + 2 * i, -+ hw->ext_buttons & (1 << (i + ext_bits))); -+ } - } - - static void synaptics_report_slot(struct input_dev *dev, int slot, --- -2.1.0 - diff --git a/freed-ora/current/f20/Input-synaptics-handle-spurious-release-of-trackstic.patch b/freed-ora/current/f20/Input-synaptics-handle-spurious-release-of-trackstic.patch deleted file mode 100644 index e3d3d7af0..000000000 --- a/freed-ora/current/f20/Input-synaptics-handle-spurious-release-of-trackstic.patch +++ /dev/null @@ -1,77 +0,0 @@ -From: Benjamin Tissoires <benjamin.tissoires@redhat.com> -Date: Sun, 8 Mar 2015 22:32:43 -0700 -Subject: [PATCH] Input: synaptics - handle spurious release of trackstick - buttons - -The Fimware 8.1 has a bug in which the extra buttons are only sent when the -ExtBit is 1. This should be fixed in a future FW update which should have -a bump of the minor version. - -Cc: stable@vger.kernel.org -Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> -Acked-by: Hans de Goede <hdegoede@redhat.com> -Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> ---- - drivers/input/mouse/synaptics.c | 33 +++++++++++++++++++++++++-------- - 1 file changed, 25 insertions(+), 8 deletions(-) - -diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c -index e78cc5578527..2f42a712f3e0 100644 ---- a/drivers/input/mouse/synaptics.c -+++ b/drivers/input/mouse/synaptics.c -@@ -820,14 +820,36 @@ static void synaptics_report_semi_mt_data(struct input_dev *dev, - } - } - --static void synaptics_report_buttons(struct psmouse *psmouse, -- const struct synaptics_hw_state *hw) -+static void synaptics_report_ext_buttons(struct psmouse *psmouse, -+ const struct synaptics_hw_state *hw) - { - struct input_dev *dev = psmouse->dev; - struct synaptics_data *priv = psmouse->private; - int ext_bits = (SYN_CAP_MULTI_BUTTON_NO(priv->ext_cap) + 1) >> 1; - int i; - -+ if (!SYN_CAP_MULTI_BUTTON_NO(priv->ext_cap)) -+ return; -+ -+ /* Bug in FW 8.1, buttons are reported only when ExtBit is 1 */ -+ if (SYN_ID_FULL(priv->identity) == 0x801 && -+ !((psmouse->packet[0] ^ psmouse->packet[3]) & 0x02)) -+ return; -+ -+ for (i = 0; i < ext_bits; i++) { -+ input_report_key(dev, BTN_0 + 2 * i, -+ hw->ext_buttons & (1 << i)); -+ input_report_key(dev, BTN_1 + 2 * i, -+ hw->ext_buttons & (1 << (i + ext_bits))); -+ } -+} -+ -+static void synaptics_report_buttons(struct psmouse *psmouse, -+ const struct synaptics_hw_state *hw) -+{ -+ struct input_dev *dev = psmouse->dev; -+ struct synaptics_data *priv = psmouse->private; -+ - input_report_key(dev, BTN_LEFT, hw->left); - input_report_key(dev, BTN_RIGHT, hw->right); - -@@ -839,12 +861,7 @@ static void synaptics_report_buttons(struct psmouse *psmouse, - input_report_key(dev, BTN_BACK, hw->down); - } - -- for (i = 0; i < ext_bits; i++) { -- input_report_key(dev, BTN_0 + 2 * i, -- hw->ext_buttons & (1 << i)); -- input_report_key(dev, BTN_1 + 2 * i, -- hw->ext_buttons & (1 << (i + ext_bits))); -- } -+ synaptics_report_ext_buttons(psmouse, hw); - } - - static void synaptics_report_slot(struct input_dev *dev, int slot, --- -2.1.0 - diff --git a/freed-ora/current/f20/Input-synaptics-log-queried-and-quirked-dimension-va.patch b/freed-ora/current/f20/Input-synaptics-log-queried-and-quirked-dimension-va.patch deleted file mode 100644 index b6f642eba..000000000 --- a/freed-ora/current/f20/Input-synaptics-log-queried-and-quirked-dimension-va.patch +++ /dev/null @@ -1,56 +0,0 @@ -From: Daniel Martin <consume.noise@gmail.com> -Date: Sun, 8 Mar 2015 22:28:29 -0700 -Subject: [PATCH] Input: synaptics - log queried and quirked dimension values - -Logging the dimension values we queried and the values we use from a quirk -to overwrite can be helpful for debugging. - -This partly relates to bug: - https://bugzilla.kernel.org/show_bug.cgi?id=91541 - -Cc: stable@vger.kernel.org -Signed-off-by: Daniel Martin <consume.noise@gmail.com> -Acked-by: Hans de Goede <hdegoede@redhat.com> -Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> ---- - drivers/input/mouse/synaptics.c | 10 ++++++++++ - 1 file changed, 10 insertions(+) - -diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c -index b501dda75dcb..47c5dca20a60 100644 ---- a/drivers/input/mouse/synaptics.c -+++ b/drivers/input/mouse/synaptics.c -@@ -362,6 +362,9 @@ static int synaptics_resolution(struct psmouse *psmouse) - } else { - priv->x_max = (resp[0] << 5) | ((resp[1] & 0x0f) << 1); - priv->y_max = (resp[2] << 5) | ((resp[1] & 0xf0) >> 3); -+ psmouse_info(psmouse, -+ "queried max coordinates: x [..%d], y [..%d]\n", -+ priv->x_max, priv->y_max); - } - } - -@@ -373,6 +376,9 @@ static int synaptics_resolution(struct psmouse *psmouse) - } else { - priv->x_min = (resp[0] << 5) | ((resp[1] & 0x0f) << 1); - priv->y_min = (resp[2] << 5) | ((resp[1] & 0xf0) >> 3); -+ psmouse_info(psmouse, -+ "queried min coordinates: x [%d..], y [%d..]\n", -+ priv->x_min, priv->y_min); - } - } - -@@ -395,6 +401,10 @@ static void synaptics_apply_quirks(struct psmouse *psmouse) - priv->x_max = min_max_pnpid_table[i].x_max; - priv->y_min = min_max_pnpid_table[i].y_min; - priv->y_max = min_max_pnpid_table[i].y_max; -+ psmouse_info(psmouse, -+ "quirked min/max coordinates: x [%d..%d], y [%d..%d]\n", -+ priv->x_min, priv->x_max, -+ priv->y_min, priv->y_max); - break; - } - } --- -2.1.0 - diff --git a/freed-ora/current/f20/Input-synaptics-query-min-dimensions-for-fw-v8.1.patch b/freed-ora/current/f20/Input-synaptics-query-min-dimensions-for-fw-v8.1.patch deleted file mode 100644 index a4ecc6ef7..000000000 --- a/freed-ora/current/f20/Input-synaptics-query-min-dimensions-for-fw-v8.1.patch +++ /dev/null @@ -1,47 +0,0 @@ -From: Daniel Martin <consume.noise@gmail.com> -Date: Sun, 8 Mar 2015 22:28:40 -0700 -Subject: [PATCH] Input: synaptics - query min dimensions for fw v8.1 - -Query the min dimensions even if the check -SYN_EXT_CAP_REQUESTS(priv->capabilities) >= 7 fails, but we know that the -firmware version 8.1 is safe. - -With that we don't need quirks for post-2013 models anymore as they expose -correct min and max dimensions. - -Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=91541 - -Cc: stable@vger.kernel.org -Signed-off-by: Daniel Martin <consume.noise@gmail.com> - re-order the tests to check SYN_CAP_MIN_DIMENSIONS even on FW 8.1 -Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> -Acked-by: Hans de Goede <hdegoede@redhat.com> -Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> ---- - drivers/input/mouse/synaptics.c | 10 ++++++++-- - 1 file changed, 8 insertions(+), 2 deletions(-) - -diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c -index 47c5dca20a60..87c37f745b92 100644 ---- a/drivers/input/mouse/synaptics.c -+++ b/drivers/input/mouse/synaptics.c -@@ -368,8 +368,14 @@ static int synaptics_resolution(struct psmouse *psmouse) - } - } - -- if (SYN_EXT_CAP_REQUESTS(priv->capabilities) >= 7 && -- SYN_CAP_MIN_DIMENSIONS(priv->ext_cap_0c)) { -+ if (SYN_CAP_MIN_DIMENSIONS(priv->ext_cap_0c) && -+ (SYN_EXT_CAP_REQUESTS(priv->capabilities) >= 7 || -+ /* -+ * Firmware v8.1 does not report proper number of extended -+ * capabilities, but has been proven to report correct min -+ * coordinates. -+ */ -+ SYN_ID_FULL(priv->identity) == 0x801)) { - if (synaptics_send_cmd(psmouse, SYN_QUE_EXT_MIN_COORDS, resp)) { - psmouse_warn(psmouse, - "device claims to have min coordinates query, but I'm not able to read it.\n"); --- -2.1.0 - diff --git a/freed-ora/current/f20/Input-synaptics-remove-obsolete-min-max-quirk-for-X2.patch b/freed-ora/current/f20/Input-synaptics-remove-obsolete-min-max-quirk-for-X2.patch deleted file mode 100644 index 530507815..000000000 --- a/freed-ora/current/f20/Input-synaptics-remove-obsolete-min-max-quirk-for-X2.patch +++ /dev/null @@ -1,32 +0,0 @@ -From: Daniel Martin <consume.noise@gmail.com> -Date: Sun, 8 Mar 2015 22:29:07 -0700 -Subject: [PATCH] Input: synaptics - remove obsolete min/max quirk for X240 - -The firmware of the X240 (LEN0035, 2013/12) exposes the same values - x [1232..5710], y [1156..4696] -as the quirk applies. - -Cc: stable@vger.kernel.org -Signed-off-by: Daniel Martin <consume.noise@gmail.com> -Acked-by: Hans de Goede <hdegoede@redhat.com> -Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> ---- - drivers/input/mouse/synaptics.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c -index 87c37f745b92..af686a82b02b 100644 ---- a/drivers/input/mouse/synaptics.c -+++ b/drivers/input/mouse/synaptics.c -@@ -131,7 +131,7 @@ static const struct min_max_quirk min_max_pnpid_table[] = { - 1024, 5052, 2258, 4832 - }, - { -- (const char * const []){"LEN0035", "LEN0042", NULL}, -+ (const char * const []){"LEN0042", NULL}, - 1232, 5710, 1156, 4696 - }, - { --- -2.1.0 - diff --git a/freed-ora/current/f20/Input-synaptics-skip-quirks-when-post-2013-dimension.patch b/freed-ora/current/f20/Input-synaptics-skip-quirks-when-post-2013-dimension.patch deleted file mode 100644 index 4ab0617ef..000000000 --- a/freed-ora/current/f20/Input-synaptics-skip-quirks-when-post-2013-dimension.patch +++ /dev/null @@ -1,39 +0,0 @@ -From: Benjamin Tissoires <benjamin.tissoires@redhat.com> -Date: Sun, 8 Mar 2015 22:29:25 -0700 -Subject: [PATCH] Input: synaptics - skip quirks when post-2013 dimensions - -Post-2013 Lenovo laptops provide correct min/max dimensions, which are -different with the ones currently quirked. According to -https://bugzilla.kernel.org/show_bug.cgi?id=91541 the following board ids -are assigned in the post-2013 touchpads: - -t440p/t440s: LEN0036 -> 2964/2962 -t540p: LEN0034 -> 2964 - -Using 2961 as the common minimum makes these 3 laptops OK. We may need -to update those values later if other pnp_ids has a lower board_id. - -Cc: stable@vger.kernel.org -Signed-off-by: Benjamin Tissoires <benjamin.tissoires@redhat.com> -Acked-by: Hans de Goede <hdegoede@redhat.com> -Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> ---- - drivers/input/mouse/synaptics.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c -index a900a385e5c3..9567a708aa64 100644 ---- a/drivers/input/mouse/synaptics.c -+++ b/drivers/input/mouse/synaptics.c -@@ -144,7 +144,7 @@ static const struct min_max_quirk min_max_pnpid_table[] = { - (const char * const []){"LEN0034", "LEN0036", "LEN0037", - "LEN0039", "LEN2002", "LEN2004", - NULL}, -- {ANY_BOARD_ID, ANY_BOARD_ID}, -+ {ANY_BOARD_ID, 2961}, - 1024, 5112, 2024, 4832 - }, - { --- -2.1.0 - diff --git a/freed-ora/current/f20/Input-synaptics-split-synaptics_resolution-query-fir.patch b/freed-ora/current/f20/Input-synaptics-split-synaptics_resolution-query-fir.patch deleted file mode 100644 index 56e9e317c..000000000 --- a/freed-ora/current/f20/Input-synaptics-split-synaptics_resolution-query-fir.patch +++ /dev/null @@ -1,87 +0,0 @@ -From: Daniel Martin <consume.noise@gmail.com> -Date: Sun, 8 Mar 2015 22:27:37 -0700 -Subject: [PATCH] Input: synaptics - split synaptics_resolution(), query first - -Split the function synaptics_resolution() into synaptics_resolution() and -synaptics_quirks(). synaptics_resolution() will be called before -synaptics_quirks() to query dimensions and resolutions before overwriting -them with quirks. - -Cc: stable@vger.kernel.org -Signed-off-by: Daniel Martin <consume.noise@gmail.com> -Acked-by: Hans de Goede <hdegoede@redhat.com> -Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> ---- - drivers/input/mouse/synaptics.c | 35 +++++++++++++++++++++++------------ - 1 file changed, 23 insertions(+), 12 deletions(-) - -diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c -index 23e26e0768b5..b501dda75dcb 100644 ---- a/drivers/input/mouse/synaptics.c -+++ b/drivers/input/mouse/synaptics.c -@@ -343,7 +343,6 @@ static int synaptics_resolution(struct psmouse *psmouse) - { - struct synaptics_data *priv = psmouse->private; - unsigned char resp[3]; -- int i; - - if (SYN_ID_MAJOR(priv->identity) < 4) - return 0; -@@ -355,17 +354,6 @@ static int synaptics_resolution(struct psmouse *psmouse) - } - } - -- for (i = 0; min_max_pnpid_table[i].pnp_ids; i++) { -- if (psmouse_matches_pnp_id(psmouse, -- min_max_pnpid_table[i].pnp_ids)) { -- priv->x_min = min_max_pnpid_table[i].x_min; -- priv->x_max = min_max_pnpid_table[i].x_max; -- priv->y_min = min_max_pnpid_table[i].y_min; -- priv->y_max = min_max_pnpid_table[i].y_max; -- return 0; -- } -- } -- - if (SYN_EXT_CAP_REQUESTS(priv->capabilities) >= 5 && - SYN_CAP_MAX_DIMENSIONS(priv->ext_cap_0c)) { - if (synaptics_send_cmd(psmouse, SYN_QUE_EXT_MAX_COORDS, resp)) { -@@ -391,6 +379,27 @@ static int synaptics_resolution(struct psmouse *psmouse) - return 0; - } - -+/* -+ * Apply quirk(s) if the hardware matches -+ */ -+ -+static void synaptics_apply_quirks(struct psmouse *psmouse) -+{ -+ struct synaptics_data *priv = psmouse->private; -+ int i; -+ -+ for (i = 0; min_max_pnpid_table[i].pnp_ids; i++) { -+ if (psmouse_matches_pnp_id(psmouse, -+ min_max_pnpid_table[i].pnp_ids)) { -+ priv->x_min = min_max_pnpid_table[i].x_min; -+ priv->x_max = min_max_pnpid_table[i].x_max; -+ priv->y_min = min_max_pnpid_table[i].y_min; -+ priv->y_max = min_max_pnpid_table[i].y_max; -+ break; -+ } -+ } -+} -+ - static int synaptics_query_hardware(struct psmouse *psmouse) - { - if (synaptics_identify(psmouse)) -@@ -406,6 +415,8 @@ static int synaptics_query_hardware(struct psmouse *psmouse) - if (synaptics_resolution(psmouse)) - return -1; - -+ synaptics_apply_quirks(psmouse); -+ - return 0; - } - --- -2.1.0 - diff --git a/freed-ora/current/f20/Input-synaptics-support-min-max-board-id-in-min_max_.patch b/freed-ora/current/f20/Input-synaptics-support-min-max-board-id-in-min_max_.patch deleted file mode 100644 index cb1a255c5..000000000 --- a/freed-ora/current/f20/Input-synaptics-support-min-max-board-id-in-min_max_.patch +++ /dev/null @@ -1,108 +0,0 @@ -From: Daniel Martin <daniel.martin@secunet.com> -Date: Sun, 8 Mar 2015 22:29:15 -0700 -Subject: [PATCH] Input: synaptics - support min/max board id in - min_max_pnpid_table - -Add a min/max range for board ids to the min/max coordinates quirk. This -makes it possible to restrict quirks to specific models based upon their -board id. The define ANY_BOARD_ID (0) serves as a wild card. - -Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=91541 - -Cc: stable@vger.kernel.org -Signed-off-by: Daniel Martin <daniel.martin@secunet.com> -Acked-by: Hans de Goede <hdegoede@redhat.com> -Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> ---- - drivers/input/mouse/synaptics.c | 42 +++++++++++++++++++++++++++++------------ - 1 file changed, 30 insertions(+), 12 deletions(-) - -diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c -index af686a82b02b..a900a385e5c3 100644 ---- a/drivers/input/mouse/synaptics.c -+++ b/drivers/input/mouse/synaptics.c -@@ -120,32 +120,41 @@ void synaptics_reset(struct psmouse *psmouse) - - static bool cr48_profile_sensor; - -+#define ANY_BOARD_ID 0 - struct min_max_quirk { - const char * const *pnp_ids; -+ struct { -+ unsigned long int min, max; -+ } board_id; - int x_min, x_max, y_min, y_max; - }; - - static const struct min_max_quirk min_max_pnpid_table[] = { - { - (const char * const []){"LEN0033", NULL}, -+ {ANY_BOARD_ID, ANY_BOARD_ID}, - 1024, 5052, 2258, 4832 - }, - { - (const char * const []){"LEN0042", NULL}, -+ {ANY_BOARD_ID, ANY_BOARD_ID}, - 1232, 5710, 1156, 4696 - }, - { - (const char * const []){"LEN0034", "LEN0036", "LEN0037", - "LEN0039", "LEN2002", "LEN2004", - NULL}, -+ {ANY_BOARD_ID, ANY_BOARD_ID}, - 1024, 5112, 2024, 4832 - }, - { - (const char * const []){"LEN2001", NULL}, -+ {ANY_BOARD_ID, ANY_BOARD_ID}, - 1024, 5022, 2508, 4832 - }, - { - (const char * const []){"LEN2006", NULL}, -+ {ANY_BOARD_ID, ANY_BOARD_ID}, - 1264, 5675, 1171, 4688 - }, - { } -@@ -401,18 +410,27 @@ static void synaptics_apply_quirks(struct psmouse *psmouse) - int i; - - for (i = 0; min_max_pnpid_table[i].pnp_ids; i++) { -- if (psmouse_matches_pnp_id(psmouse, -- min_max_pnpid_table[i].pnp_ids)) { -- priv->x_min = min_max_pnpid_table[i].x_min; -- priv->x_max = min_max_pnpid_table[i].x_max; -- priv->y_min = min_max_pnpid_table[i].y_min; -- priv->y_max = min_max_pnpid_table[i].y_max; -- psmouse_info(psmouse, -- "quirked min/max coordinates: x [%d..%d], y [%d..%d]\n", -- priv->x_min, priv->x_max, -- priv->y_min, priv->y_max); -- break; -- } -+ if (!psmouse_matches_pnp_id(psmouse, -+ min_max_pnpid_table[i].pnp_ids)) -+ continue; -+ -+ if (min_max_pnpid_table[i].board_id.min != ANY_BOARD_ID && -+ priv->board_id < min_max_pnpid_table[i].board_id.min) -+ continue; -+ -+ if (min_max_pnpid_table[i].board_id.max != ANY_BOARD_ID && -+ priv->board_id > min_max_pnpid_table[i].board_id.max) -+ continue; -+ -+ priv->x_min = min_max_pnpid_table[i].x_min; -+ priv->x_max = min_max_pnpid_table[i].x_max; -+ priv->y_min = min_max_pnpid_table[i].y_min; -+ priv->y_max = min_max_pnpid_table[i].y_max; -+ psmouse_info(psmouse, -+ "quirked min/max coordinates: x [%d..%d], y [%d..%d]\n", -+ priv->x_min, priv->x_max, -+ priv->y_min, priv->y_max); -+ break; - } - } - --- -2.1.0 - diff --git a/freed-ora/current/f20/ipv6-Don-t-reduce-hop-limit-for-an-interface.patch b/freed-ora/current/f20/ipv6-Don-t-reduce-hop-limit-for-an-interface.patch new file mode 100644 index 000000000..60f2490ee --- /dev/null +++ b/freed-ora/current/f20/ipv6-Don-t-reduce-hop-limit-for-an-interface.patch @@ -0,0 +1,46 @@ +From: "D.S. Ljungmark" <ljungmark@modio.se> +Date: Wed, 25 Mar 2015 09:28:15 +0100 +Subject: [PATCH] ipv6: Don't reduce hop limit for an interface + +A local route may have a lower hop_limit set than global routes do. + +RFC 3756, Section 4.2.7, "Parameter Spoofing" + +> 1. The attacker includes a Current Hop Limit of one or another small +> number which the attacker knows will cause legitimate packets to +> be dropped before they reach their destination. + +> As an example, one possible approach to mitigate this threat is to +> ignore very small hop limits. The nodes could implement a +> configurable minimum hop limit, and ignore attempts to set it below +> said limit. + +Signed-off-by: D.S. Ljungmark <ljungmark@modio.se> +Acked-by: Hannes Frederic Sowa <hannes@stressinduktion.org> +--- + net/ipv6/ndisc.c | 9 ++++++++- + 1 file changed, 8 insertions(+), 1 deletion(-) + +diff --git a/net/ipv6/ndisc.c b/net/ipv6/ndisc.c +index 682866777d53..d375ce60463e 100644 +--- a/net/ipv6/ndisc.c ++++ b/net/ipv6/ndisc.c +@@ -1216,7 +1216,14 @@ static void ndisc_router_discovery(struct sk_buff *skb) + if (rt) + rt6_set_expires(rt, jiffies + (HZ * lifetime)); + if (ra_msg->icmph.icmp6_hop_limit) { +- in6_dev->cnf.hop_limit = ra_msg->icmph.icmp6_hop_limit; ++ /* Only set hop_limit on the interface if it is higher than ++ * the current hop_limit. ++ */ ++ if (in6_dev->cnf.hop_limit < ra_msg->icmph.icmp6_hop_limit) { ++ in6_dev->cnf.hop_limit = ra_msg->icmph.icmp6_hop_limit; ++ } else { ++ ND_PRINTK(2, warn, "RA: Got route advertisement with lower hop_limit than current\n"); ++ } + if (rt) + dst_metric_set(&rt->dst, RTAX_HOPLIMIT, + ra_msg->icmph.icmp6_hop_limit); +-- +2.1.0 + diff --git a/freed-ora/current/f20/kernel.spec b/freed-ora/current/f20/kernel.spec index 1a39fa677..58c23c21a 100644 --- a/freed-ora/current/f20/kernel.spec +++ b/freed-ora/current/f20/kernel.spec @@ -112,7 +112,7 @@ Summary: The Linux kernel %if 0%{?released_kernel} # Do we have a -stable update to apply? -%define stable_update 3 +%define stable_update 4 # Is it a -stable RC? %define stable_rc 0 # Set rpm version accordingly @@ -802,15 +802,6 @@ Patch26138: ext4-Allocate-entire-range-in-zero-range.patch Patch26141: Bluetooth-ath3k-Add-support-Atheros-AR5B195-combo-Mi.patch #rhbz 1200777 1200778 -Patch26150: Input-synaptics-split-synaptics_resolution-query-fir.patch -Patch26151: Input-synaptics-log-queried-and-quirked-dimension-va.patch -Patch26152: Input-synaptics-query-min-dimensions-for-fw-v8.1.patch -Patch26153: Input-synaptics-remove-obsolete-min-max-quirk-for-X2.patch -Patch26154: Input-synaptics-support-min-max-board-id-in-min_max_.patch -Patch26155: Input-synaptics-skip-quirks-when-post-2013-dimension.patch -Patch26156: Input-synaptics-fix-middle-button-on-Lenovo-2015-pro.patch -Patch26157: Input-synaptics-handle-spurious-release-of-trackstic.patch -Patch26158: Input-synaptics-do-not-retrieve-the-board-id-on-old-.patch Patch26159: Input-synaptics-retrieve-the-extended-capabilities-i.patch Patch26160: Input-synaptics-remove-TOPBUTTONPAD-property-for-Len.patch Patch26161: Input-synaptics-re-route-tracksticks-buttons-on-the-.patch @@ -836,6 +827,18 @@ Patch30000: kernel-arm64.patch #rhbz 1204512 Patch26174: tun-return-proper-error-code-from-tun_do_read.patch +#CVE-2015-2150 rhbz 1196266 1200397 +Patch26175: xen-pciback-Don-t-disable-PCI_COMMAND-on-PCI-device-.patch + +#rhbz 1203913 +Patch26176: sunrpc-make-debugfs-file-creation-failure-non-fatal.patch + +#rhbz 1207789 +Patch26177: tg3-Hold-tp-lock-before-calling-tg3_halt-from-tg3_in.patch + +#CVE-2015-XXXX rhbz 1203712 1208491 +Patch26178: ipv6-Don-t-reduce-hop-limit-for-an-interface.patch + # END OF PATCH DEFINITIONS %endif @@ -1603,15 +1606,6 @@ ApplyPatch ext4-Allocate-entire-range-in-zero-range.patch ApplyPatch Bluetooth-ath3k-Add-support-Atheros-AR5B195-combo-Mi.patch #rhbz 1200777 1200778 -ApplyPatch Input-synaptics-split-synaptics_resolution-query-fir.patch -ApplyPatch Input-synaptics-log-queried-and-quirked-dimension-va.patch -ApplyPatch Input-synaptics-query-min-dimensions-for-fw-v8.1.patch -ApplyPatch Input-synaptics-remove-obsolete-min-max-quirk-for-X2.patch -ApplyPatch Input-synaptics-support-min-max-board-id-in-min_max_.patch -ApplyPatch Input-synaptics-skip-quirks-when-post-2013-dimension.patch -ApplyPatch Input-synaptics-fix-middle-button-on-Lenovo-2015-pro.patch -ApplyPatch Input-synaptics-handle-spurious-release-of-trackstic.patch -ApplyPatch Input-synaptics-do-not-retrieve-the-board-id-on-old-.patch ApplyPatch Input-synaptics-retrieve-the-extended-capabilities-i.patch ApplyPatch Input-synaptics-remove-TOPBUTTONPAD-property-for-Len.patch ApplyPatch Input-synaptics-re-route-tracksticks-buttons-on-the-.patch @@ -1641,6 +1635,18 @@ ApplyPatch kernel-arm64.patch -R #rhbz 1204512 ApplyPatch tun-return-proper-error-code-from-tun_do_read.patch +#CVE-2015-2150 rhbz 1196266 1200397 +ApplyPatch xen-pciback-Don-t-disable-PCI_COMMAND-on-PCI-device-.patch + +#rhbz 1203913 +ApplyPatch sunrpc-make-debugfs-file-creation-failure-non-fatal.patch + +#rhbz 1207789 +ApplyPatch tg3-Hold-tp-lock-before-calling-tg3_halt-from-tg3_in.patch + +#CVE-2015-XXXX rhbz 1203712 1208491 +ApplyPatch ipv6-Don-t-reduce-hop-limit-for-an-interface.patch + # END OF PATCH APPLICATIONS %endif @@ -2463,6 +2469,20 @@ fi # ||----w | # || || %changelog +* Mon Apr 13 2015 Alexandre Oliva <lxoliva@fsfla.org> -libre +- GNU Linux-libre 3.19.4-gnu. + +* Mon Apr 13 2015 Justin M. Forbes <jforbes@fedoraproject.org> - 3.19.4-100 +- Linux v3.19.4 + +* Thu Apr 02 2015 Josh Boyer <jwboyer@fedoraproject.org> +- DoS against IPv6 stacks due to improper handling of RA (rhbz 1203712 1208491) + +* Wed Apr 01 2015 Josh Boyer <jwboyer@fedoraproject.org> +- Backport patch to fix tg3 deadlock (rhbz 1207789) +- Fix gssproxy (rhbz 1203913) +- CVE-2015-2150 xen: NMIs triggerable by guests (rhbz 1196266 1200397) + * Fri Mar 27 2015 Alexandre Oliva <lxoliva@fsfla.org> -libre - GNU Linux-libre 3.19.3-gnu. diff --git a/freed-ora/current/f20/sources b/freed-ora/current/f20/sources index 40dd915c2..acdd33a9e 100644 --- a/freed-ora/current/f20/sources +++ b/freed-ora/current/f20/sources @@ -1,3 +1,3 @@ 6b6245298a846bae9842bc4558eee172 linux-libre-3.19-gnu.tar.xz 15d8d2f97ce056488451a5bfb2944603 perf-man-3.19.tar.gz -1fec75551b2f55fced43df8394b1fd9a patch-3.19.3.xz +0dc19b6abb9b7ae05ba7da48e29c984f patch-3.19.4.xz diff --git a/freed-ora/current/f20/sunrpc-make-debugfs-file-creation-failure-non-fatal.patch b/freed-ora/current/f20/sunrpc-make-debugfs-file-creation-failure-non-fatal.patch new file mode 100644 index 000000000..433fa8ece --- /dev/null +++ b/freed-ora/current/f20/sunrpc-make-debugfs-file-creation-failure-non-fatal.patch @@ -0,0 +1,303 @@ +From: Jeff Layton <jlayton@poochiereds.net> +Date: Tue, 31 Mar 2015 12:03:28 -0400 +Subject: [PATCH] sunrpc: make debugfs file creation failure non-fatal + +We currently have a problem that SELinux policy is being enforced when +creating debugfs files. If a debugfs file is created as a side effect of +doing some syscall, then that creation can fail if the SELinux policy +for that process prevents it. + +This seems wrong. We don't do that for files under /proc, for instance, +so Bruce has proposed a patch to fix that. + +While discussing that patch however, Greg K.H. stated: + + "No kernel code should care / fail if a debugfs function fails, so + please fix up the sunrpc code first." + +This patch converts all of the sunrpc debugfs setup code to be void +return functins, and the callers to not look for errors from those +functions. + +This should allow rpc_clnt and rpc_xprt creation to work, even if the +kernel fails to create debugfs files for some reason. + +Symptoms were failing krb5 mounts on systems using gss-proxy and +selinux. + +Fixes: 388f0c776781 "sunrpc: add a debugfs rpc_xprt directory..." +Cc: stable@vger.kernel.org +Signed-off-by: Jeff Layton <jeff.layton@primarydata.com> +Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> +Signed-off-by: J. Bruce Fields <bfields@redhat.com> +--- + include/linux/sunrpc/debug.h | 18 +++++++-------- + net/sunrpc/clnt.c | 4 +--- + net/sunrpc/debugfs.c | 52 ++++++++++++++++++++++++-------------------- + net/sunrpc/sunrpc_syms.c | 7 +----- + net/sunrpc/xprt.c | 7 +----- + 5 files changed, 41 insertions(+), 47 deletions(-) + +diff --git a/include/linux/sunrpc/debug.h b/include/linux/sunrpc/debug.h +index c57d8ea0716c..59a7889e15db 100644 +--- a/include/linux/sunrpc/debug.h ++++ b/include/linux/sunrpc/debug.h +@@ -60,17 +60,17 @@ struct rpc_xprt; + #if IS_ENABLED(CONFIG_SUNRPC_DEBUG) + void rpc_register_sysctl(void); + void rpc_unregister_sysctl(void); +-int sunrpc_debugfs_init(void); ++void sunrpc_debugfs_init(void); + void sunrpc_debugfs_exit(void); +-int rpc_clnt_debugfs_register(struct rpc_clnt *); ++void rpc_clnt_debugfs_register(struct rpc_clnt *); + void rpc_clnt_debugfs_unregister(struct rpc_clnt *); +-int rpc_xprt_debugfs_register(struct rpc_xprt *); ++void rpc_xprt_debugfs_register(struct rpc_xprt *); + void rpc_xprt_debugfs_unregister(struct rpc_xprt *); + #else +-static inline int ++static inline void + sunrpc_debugfs_init(void) + { +- return 0; ++ return; + } + + static inline void +@@ -79,10 +79,10 @@ sunrpc_debugfs_exit(void) + return; + } + +-static inline int ++static inline void + rpc_clnt_debugfs_register(struct rpc_clnt *clnt) + { +- return 0; ++ return; + } + + static inline void +@@ -91,10 +91,10 @@ rpc_clnt_debugfs_unregister(struct rpc_clnt *clnt) + return; + } + +-static inline int ++static inline void + rpc_xprt_debugfs_register(struct rpc_xprt *xprt) + { +- return 0; ++ return; + } + + static inline void +diff --git a/net/sunrpc/clnt.c b/net/sunrpc/clnt.c +index 3f5d4d48f0cb..86e6cc5c0953 100644 +--- a/net/sunrpc/clnt.c ++++ b/net/sunrpc/clnt.c +@@ -303,9 +303,7 @@ static int rpc_client_register(struct rpc_clnt *clnt, + struct super_block *pipefs_sb; + int err; + +- err = rpc_clnt_debugfs_register(clnt); +- if (err) +- return err; ++ rpc_clnt_debugfs_register(clnt); + + pipefs_sb = rpc_get_sb_net(net); + if (pipefs_sb) { +diff --git a/net/sunrpc/debugfs.c b/net/sunrpc/debugfs.c +index e811f390f9f6..82962f7e6e88 100644 +--- a/net/sunrpc/debugfs.c ++++ b/net/sunrpc/debugfs.c +@@ -129,48 +129,52 @@ static const struct file_operations tasks_fops = { + .release = tasks_release, + }; + +-int ++void + rpc_clnt_debugfs_register(struct rpc_clnt *clnt) + { +- int len, err; ++ int len; + char name[24]; /* enough for "../../rpc_xprt/ + 8 hex digits + NULL */ ++ struct rpc_xprt *xprt; + + /* Already registered? */ +- if (clnt->cl_debugfs) +- return 0; ++ if (clnt->cl_debugfs || !rpc_clnt_dir) ++ return; + + len = snprintf(name, sizeof(name), "%x", clnt->cl_clid); + if (len >= sizeof(name)) +- return -EINVAL; ++ return; + + /* make the per-client dir */ + clnt->cl_debugfs = debugfs_create_dir(name, rpc_clnt_dir); + if (!clnt->cl_debugfs) +- return -ENOMEM; ++ return; + + /* make tasks file */ +- err = -ENOMEM; + if (!debugfs_create_file("tasks", S_IFREG | S_IRUSR, clnt->cl_debugfs, + clnt, &tasks_fops)) + goto out_err; + +- err = -EINVAL; + rcu_read_lock(); ++ xprt = rcu_dereference(clnt->cl_xprt); ++ /* no "debugfs" dentry? Don't bother with the symlink. */ ++ if (!xprt->debugfs) { ++ rcu_read_unlock(); ++ return; ++ } + len = snprintf(name, sizeof(name), "../../rpc_xprt/%s", +- rcu_dereference(clnt->cl_xprt)->debugfs->d_name.name); ++ xprt->debugfs->d_name.name); + rcu_read_unlock(); ++ + if (len >= sizeof(name)) + goto out_err; + +- err = -ENOMEM; + if (!debugfs_create_symlink("xprt", clnt->cl_debugfs, name)) + goto out_err; + +- return 0; ++ return; + out_err: + debugfs_remove_recursive(clnt->cl_debugfs); + clnt->cl_debugfs = NULL; +- return err; + } + + void +@@ -226,33 +230,33 @@ static const struct file_operations xprt_info_fops = { + .release = xprt_info_release, + }; + +-int ++void + rpc_xprt_debugfs_register(struct rpc_xprt *xprt) + { + int len, id; + static atomic_t cur_id; + char name[9]; /* 8 hex digits + NULL term */ + ++ if (!rpc_xprt_dir) ++ return; ++ + id = (unsigned int)atomic_inc_return(&cur_id); + + len = snprintf(name, sizeof(name), "%x", id); + if (len >= sizeof(name)) +- return -EINVAL; ++ return; + + /* make the per-client dir */ + xprt->debugfs = debugfs_create_dir(name, rpc_xprt_dir); + if (!xprt->debugfs) +- return -ENOMEM; ++ return; + + /* make tasks file */ + if (!debugfs_create_file("info", S_IFREG | S_IRUSR, xprt->debugfs, + xprt, &xprt_info_fops)) { + debugfs_remove_recursive(xprt->debugfs); + xprt->debugfs = NULL; +- return -ENOMEM; + } +- +- return 0; + } + + void +@@ -266,14 +270,17 @@ void __exit + sunrpc_debugfs_exit(void) + { + debugfs_remove_recursive(topdir); ++ topdir = NULL; ++ rpc_clnt_dir = NULL; ++ rpc_xprt_dir = NULL; + } + +-int __init ++void __init + sunrpc_debugfs_init(void) + { + topdir = debugfs_create_dir("sunrpc", NULL); + if (!topdir) +- goto out; ++ return; + + rpc_clnt_dir = debugfs_create_dir("rpc_clnt", topdir); + if (!rpc_clnt_dir) +@@ -283,10 +290,9 @@ sunrpc_debugfs_init(void) + if (!rpc_xprt_dir) + goto out_remove; + +- return 0; ++ return; + out_remove: + debugfs_remove_recursive(topdir); + topdir = NULL; +-out: +- return -ENOMEM; ++ rpc_clnt_dir = NULL; + } +diff --git a/net/sunrpc/sunrpc_syms.c b/net/sunrpc/sunrpc_syms.c +index e37fbed87956..ee5d3d253102 100644 +--- a/net/sunrpc/sunrpc_syms.c ++++ b/net/sunrpc/sunrpc_syms.c +@@ -98,10 +98,7 @@ init_sunrpc(void) + if (err) + goto out4; + +- err = sunrpc_debugfs_init(); +- if (err) +- goto out5; +- ++ sunrpc_debugfs_init(); + #if IS_ENABLED(CONFIG_SUNRPC_DEBUG) + rpc_register_sysctl(); + #endif +@@ -109,8 +106,6 @@ init_sunrpc(void) + init_socket_xprt(); /* clnt sock transport */ + return 0; + +-out5: +- unregister_rpc_pipefs(); + out4: + unregister_pernet_subsys(&sunrpc_net_ops); + out3: +diff --git a/net/sunrpc/xprt.c b/net/sunrpc/xprt.c +index ebbefad21a37..5dcf7eac30a6 100644 +--- a/net/sunrpc/xprt.c ++++ b/net/sunrpc/xprt.c +@@ -1303,7 +1303,6 @@ static void xprt_init(struct rpc_xprt *xprt, struct net *net) + */ + struct rpc_xprt *xprt_create_transport(struct xprt_create *args) + { +- int err; + struct rpc_xprt *xprt; + struct xprt_class *t; + +@@ -1344,11 +1343,7 @@ found: + return ERR_PTR(-ENOMEM); + } + +- err = rpc_xprt_debugfs_register(xprt); +- if (err) { +- xprt_destroy(xprt); +- return ERR_PTR(err); +- } ++ rpc_xprt_debugfs_register(xprt); + + dprintk("RPC: created transport %p with %u slots\n", xprt, + xprt->max_reqs); +-- +2.1.0 + diff --git a/freed-ora/current/f20/tg3-Hold-tp-lock-before-calling-tg3_halt-from-tg3_in.patch b/freed-ora/current/f20/tg3-Hold-tp-lock-before-calling-tg3_halt-from-tg3_in.patch new file mode 100644 index 000000000..b65d0a05b --- /dev/null +++ b/freed-ora/current/f20/tg3-Hold-tp-lock-before-calling-tg3_halt-from-tg3_in.patch @@ -0,0 +1,44 @@ +From: "Jun'ichi Nomura \\(NEC\\)" <j-nomura@ce.jp.nec.com> +Date: Thu, 12 Feb 2015 01:26:24 +0000 +Subject: [PATCH] tg3: Hold tp->lock before calling tg3_halt() from + tg3_init_one() + +tg3_init_one() calls tg3_halt() without tp->lock despite its assumption +and causes deadlock. +If lockdep is enabled, a warning like this shows up before the stall: + + [ BUG: bad unlock balance detected! ] + 3.19.0test #3 Tainted: G E + ------------------------------------- + insmod/369 is trying to release lock (&(&tp->lock)->rlock) at: + [<ffffffffa02d5a1d>] tg3_chip_reset+0x14d/0x780 [tg3] + but there are no more locks to release! + +tg3_init_one() doesn't call tg3_halt() under normal situation but +during kexec kdump I hit this problem. + +Fixes: 932f19de ("tg3: Release tp->lock before invoking synchronize_irq()") +Signed-off-by: Jun'ichi Nomura <j-nomura@ce.jp.nec.com> +Signed-off-by: David S. Miller <davem@davemloft.net> +--- + drivers/net/ethernet/broadcom/tg3.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/drivers/net/ethernet/broadcom/tg3.c b/drivers/net/ethernet/broadcom/tg3.c +index 96bf01ba32dd..05ae12690117 100644 +--- a/drivers/net/ethernet/broadcom/tg3.c ++++ b/drivers/net/ethernet/broadcom/tg3.c +@@ -17868,8 +17868,10 @@ static int tg3_init_one(struct pci_dev *pdev, + */ + if ((tr32(HOSTCC_MODE) & HOSTCC_MODE_ENABLE) || + (tr32(WDMAC_MODE) & WDMAC_MODE_ENABLE)) { ++ tg3_full_lock(tp, 0); + tw32(MEMARB_MODE, MEMARB_MODE_ENABLE); + tg3_halt(tp, RESET_KIND_SHUTDOWN, 1); ++ tg3_full_unlock(tp); + } + + err = tg3_test_dma(tp); +-- +2.1.0 + diff --git a/freed-ora/current/f20/xen-pciback-Don-t-disable-PCI_COMMAND-on-PCI-device-.patch b/freed-ora/current/f20/xen-pciback-Don-t-disable-PCI_COMMAND-on-PCI-device-.patch new file mode 100644 index 000000000..de3565152 --- /dev/null +++ b/freed-ora/current/f20/xen-pciback-Don-t-disable-PCI_COMMAND-on-PCI-device-.patch @@ -0,0 +1,51 @@ +From: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> +Date: Fri, 27 Mar 2015 13:31:11 -0400 +Subject: [PATCH] xen/pciback: Don't disable PCI_COMMAND on PCI device reset. + +There is no need for this at all. Worst it means that if +the guest tries to write to BARs it could lead (on certain +platforms) to PCI SERR errors. + +Please note that with af6fc858a35b90e89ea7a7ee58e66628c55c776b +"xen-pciback: limit guest control of command register" +a guest is still allowed to enable those control bits (safely), but +is not allowed to disable them and that therefore a well behaved +frontend which enables things before using them will still +function correctly. + +This is done via an write to the configuration register 0x4 which +triggers on the backend side: +command_write + \- pci_enable_device + \- pci_enable_device_flags + \- do_pci_enable_device + \- pcibios_enable_device + \-pci_enable_resourcess + [which enables the PCI_COMMAND_MEMORY|PCI_COMMAND_IO] + +However guests (and drivers) which don't do this could cause +problems, including the security issues which XSA-120 sought +to address. + +Reported-by: Jan Beulich <jbeulich@suse.com> +Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> +--- + drivers/xen/xen-pciback/pciback_ops.c | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/drivers/xen/xen-pciback/pciback_ops.c b/drivers/xen/xen-pciback/pciback_ops.c +index c4a0666de6f5..26e651336787 100644 +--- a/drivers/xen/xen-pciback/pciback_ops.c ++++ b/drivers/xen/xen-pciback/pciback_ops.c +@@ -119,8 +119,6 @@ void xen_pcibk_reset_device(struct pci_dev *dev) + if (pci_is_enabled(dev)) + pci_disable_device(dev); + +- pci_write_config_word(dev, PCI_COMMAND, 0); +- + dev->is_busmaster = 0; + } else { + pci_read_config_word(dev, PCI_COMMAND, &cmd); +-- +2.1.0 + |