]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - mm/memory-failure.c
Merge tag 'for-5.4/io_uring-2019-09-24' of git://git.kernel.dk/linux-block
[linux.git] / mm / memory-failure.c
index d9cc6606f4097e13175a2dd3eb08523a184e1968..7ef849da8278c1ce659f4930c5df17fbe7e2f7d5 100644 (file)
@@ -213,12 +213,12 @@ static int kill_proc(struct to_kill *tk, unsigned long pfn, int flags)
        short addr_lsb = tk->size_shift;
        int ret;
 
-       pr_err("Memory failure: %#lx: Killing %s:%d due to hardware memory corruption\n",
+       pr_err("Memory failure: %#lx: Sending SIGBUS to %s:%d due to hardware memory corruption\n",
                pfn, t->comm, t->pid);
 
        if ((flags & MF_ACTION_REQUIRED) && t->mm == current->mm) {
                ret = force_sig_mceerr(BUS_MCEERR_AR, (void __user *)tk->addr,
-                                      addr_lsb, current);
+                                      addr_lsb);
        } else {
                /*
                 * Don't use force here, it's convenient if the signal
@@ -1177,16 +1177,12 @@ static int memory_failure_dev_pagemap(unsigned long pfn, int flags,
                goto unlock;
        }
 
-       switch (pgmap->type) {
-       case MEMORY_DEVICE_PRIVATE:
-       case MEMORY_DEVICE_PUBLIC:
+       if (pgmap->type == MEMORY_DEVICE_PRIVATE) {
                /*
                 * TODO: Handle HMM pages which may need coordination
                 * with device-side memory.
                 */
                goto unlock;
-       default:
-               break;
        }
 
        /*