From 8307ba83816dc5e2b6a7ff695516d7071f5d19b3 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Wed, 22 Aug 2018 10:34:15 +0200 Subject: [PATCH] 4.18-stable patches added patches: edac-add-missing-mem_lrddr4-entry-in-edac_mem_types.patch pty-fix-o_cloexec-for-tiocgptpeer.patch --- ...g-mem_lrddr4-entry-in-edac_mem_types.patch | 36 +++++++++++++++++++ .../pty-fix-o_cloexec-for-tiocgptpeer.patch | 32 +++++++++++++++++ queue-4.18/series | 2 ++ 3 files changed, 70 insertions(+) create mode 100644 queue-4.18/edac-add-missing-mem_lrddr4-entry-in-edac_mem_types.patch create mode 100644 queue-4.18/pty-fix-o_cloexec-for-tiocgptpeer.patch create mode 100644 queue-4.18/series diff --git a/queue-4.18/edac-add-missing-mem_lrddr4-entry-in-edac_mem_types.patch b/queue-4.18/edac-add-missing-mem_lrddr4-entry-in-edac_mem_types.patch new file mode 100644 index 00000000000..3eb241b7204 --- /dev/null +++ b/queue-4.18/edac-add-missing-mem_lrddr4-entry-in-edac_mem_types.patch @@ -0,0 +1,36 @@ +From b748f2de4b2f578599f46c6000683a8da755bf68 Mon Sep 17 00:00:00 2001 +From: Takashi Iwai +Date: Fri, 10 Aug 2018 16:14:26 +0200 +Subject: EDAC: Add missing MEM_LRDDR4 entry in edac_mem_types[] + +From: Takashi Iwai + +commit b748f2de4b2f578599f46c6000683a8da755bf68 upstream. + +The edac_mem_types[] array misses a MEM_LRDDR4 entry, which leads to +NULL pointer dereference when accessed via sysfs or such. + +Signed-off-by: Takashi Iwai +Cc: Mauro Carvalho Chehab +Cc: Yazen Ghannam +Cc: linux-edac +Cc: +Link: http://lkml.kernel.org/r/20180810141426.8918-1-tiwai@suse.de +Fixes: 1e8096bb2031 ("EDAC: Add LRDDR4 DRAM type") +Signed-off-by: Borislav Petkov +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/edac/edac_mc.c | 1 + + 1 file changed, 1 insertion(+) + +--- a/drivers/edac/edac_mc.c ++++ b/drivers/edac/edac_mc.c +@@ -215,6 +215,7 @@ const char * const edac_mem_types[] = { + [MEM_LRDDR3] = "Load-Reduced-DDR3-RAM", + [MEM_DDR4] = "Unbuffered-DDR4", + [MEM_RDDR4] = "Registered-DDR4", ++ [MEM_LRDDR4] = "Load-Reduced-DDR4-RAM", + [MEM_NVDIMM] = "Non-volatile-RAM", + }; + EXPORT_SYMBOL_GPL(edac_mem_types); diff --git a/queue-4.18/pty-fix-o_cloexec-for-tiocgptpeer.patch b/queue-4.18/pty-fix-o_cloexec-for-tiocgptpeer.patch new file mode 100644 index 00000000000..927cb6cdb1a --- /dev/null +++ b/queue-4.18/pty-fix-o_cloexec-for-tiocgptpeer.patch @@ -0,0 +1,32 @@ +From 36ecc1481dc8d8c52d43ba18c6b642c1d2fde789 Mon Sep 17 00:00:00 2001 +From: Matthijs van Duin +Date: Thu, 19 Jul 2018 10:43:46 +0200 +Subject: pty: fix O_CLOEXEC for TIOCGPTPEER + +From: Matthijs van Duin + +commit 36ecc1481dc8d8c52d43ba18c6b642c1d2fde789 upstream. + +It was being ignored because the flags were not passed to fd allocation. + +Fixes: 54ebbfb16034 ("tty: add TIOCGPTPEER ioctl") +Signed-off-by: Matthijs van Duin +Acked-by: Aleksa Sarai +Cc: stable +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/tty/pty.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/drivers/tty/pty.c ++++ b/drivers/tty/pty.c +@@ -625,7 +625,7 @@ int ptm_open_peer(struct file *master, s + if (tty->driver != ptm_driver) + return -EIO; + +- fd = get_unused_fd_flags(0); ++ fd = get_unused_fd_flags(flags); + if (fd < 0) { + retval = fd; + goto err; diff --git a/queue-4.18/series b/queue-4.18/series new file mode 100644 index 00000000000..98dd77b7abb --- /dev/null +++ b/queue-4.18/series @@ -0,0 +1,2 @@ +edac-add-missing-mem_lrddr4-entry-in-edac_mem_types.patch +pty-fix-o_cloexec-for-tiocgptpeer.patch -- 2.47.3