* [merged] fault-injection-handle-ei_etype_true.patch removed from -mm tree
@ 2020-12-16 17:11 akpm
0 siblings, 0 replies; only message in thread
From: akpm @ 2020-12-16 17:11 UTC (permalink / raw)
To: akinobu.mita, anil.s.keshavamurthy, davem, mhiramat, mm-commits,
naveen.n.rao, pobrn
The patch titled
Subject: fault-injection: handle EI_ETYPE_TRUE
has been removed from the -mm tree. Its filename was
fault-injection-handle-ei_etype_true.patch
This patch was dropped because it was merged into mainline or a subsystem tree
------------------------------------------------------
From: Barnabás Pőcze <pobrn@protonmail.com>
Subject: fault-injection: handle EI_ETYPE_TRUE
Commit af3b854492f351d1 ("mm/page_alloc.c: allow error injection")
introduced EI_ETYPE_TRUE, but did not extend
* lib/error-inject.c:error_type_string(), and
* kernel/fail_function.c:adjust_error_retval()
to accommodate for this change.
Handle EI_ETYPE_TRUE in both functions appropriately by
* returning "TRUE" in error_type_string(),
* adjusting the return value to true (1) in adjust_error_retval().
Furthermore, simplify the logic of handling EI_ETYPE_NULL in
adjust_error_retval().
Link: https://lkml.kernel.org/r/njB1czX0ZgWPR9h61euHIBb5bEyePw9D4D2m3i5lc9Cl96P8Q1308dTcmsEZW7Vtz3Ifz4do-rOtSfuFTyGoEDYokkK2aUqBePVptzZEWfU=@protonmail.com
Signed-off-by: Barnabás Pőcze <pobrn@protonmail.com>
Acked-by: Masami Hiramatsu <mhiramat@kernel.org>
Reviewed-by: Akinobu Mita <akinobu.mita@gmail.com>
Cc: "Naveen N. Rao" <naveen.n.rao@linux.ibm.com>
Cc: Anil S Keshavamurthy <anil.s.keshavamurthy@intel.com>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
kernel/fail_function.c | 6 +++---
lib/error-inject.c | 2 ++
2 files changed, 5 insertions(+), 3 deletions(-)
--- a/kernel/fail_function.c~fault-injection-handle-ei_etype_true
+++ a/kernel/fail_function.c
@@ -37,9 +37,7 @@ static unsigned long adjust_error_retval
{
switch (get_injectable_error_type(addr)) {
case EI_ETYPE_NULL:
- if (retv != 0)
- return 0;
- break;
+ return 0;
case EI_ETYPE_ERRNO:
if (retv < (unsigned long)-MAX_ERRNO)
return (unsigned long)-EINVAL;
@@ -48,6 +46,8 @@ static unsigned long adjust_error_retval
if (retv != 0 && retv < (unsigned long)-MAX_ERRNO)
return (unsigned long)-EINVAL;
break;
+ case EI_ETYPE_TRUE:
+ return 1;
}
return retv;
--- a/lib/error-inject.c~fault-injection-handle-ei_etype_true
+++ a/lib/error-inject.c
@@ -180,6 +180,8 @@ static const char *error_type_string(int
return "ERRNO";
case EI_ETYPE_ERRNO_NULL:
return "ERRNO_NULL";
+ case EI_ETYPE_TRUE:
+ return "TRUE";
default:
return "(unknown)";
}
_
Patches currently in -mm which might be from pobrn@protonmail.com are
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-12-16 17:12 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-16 17:11 [merged] fault-injection-handle-ei_etype_true.patch removed from -mm tree akpm
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.