Skip to contentSkip to conversation

Allow non-hcall return values for lparcfg writes

PATCH New Nathan Fontenot 1 participant 1 message Jul 25, 2008 PowerPC

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Allow non-hcall return values for lparcfg writes

The code to handle writes to /proc/ppc64/lparcfg incorrectly assumes that the return code from the helper routines to update processor or memory entitlement return a hcall return value. It then assumes any non-hcall return value is bad and sets the return code for the write to be -EIO.

The update_[mp]pp routines can return values other than a hcall return value. This patch removes the automatic setting of any return code that is not an hcall return value from these routines to -EIO.

NOTE: This patch applies on top of the CMO patches and my previous patch for lparcfg.c.

---

arch/powerpc/kernel/lparcfg.c +0 -0
Index: linux-2.6.git/arch/powerpc/kernel/lparcfg.c
===================================================================
@@ -636,10 +636,6 @@
		retval = -EIO;
	} else if (retval == H_PARAMETER) {
		retval = -EINVAL;
-	} else {
-		printk(KERN_WARNING "%s: received unknown hv return code %ld",
-		       __func__, retval);
-		retval = -EIO;
	}

	return retval;