<div dir="ltr"><div dir="ltr"><div>From: Harald Freudenberger <<a href="mailto:freude@linux.ibm.com">freude@linux.ibm.com</a>></div><div><br></div><div>BugLink: <a href="http://bugs.launchpad.net/bugs/1799184">http://bugs.launchpad.net/bugs/1799184</a></div><div><br></div><div>The sysfs attributes /sys/bus/ap/apmask and /sys/bus/ap/aqmask</div><div>and the kernel command line arguments ap.apm and ap.aqm get</div><div>an improvement of the value parsing with this patch:</div><div><br></div><div>The mask values are bitmaps in big endian order starting with bit 0.</div><div>So adapter number 0 is the leftmost bit, mask is 0x8000... The sysfs</div><div>attributes and the kernel command line accept 2 different formats:</div><div> - Absolute hex string starting with 0x like "0x12345678" does set</div><div>   the mask starting from left to right. If the given string is shorter</div><div>   than the mask it is padded with 0s on the right. If the string is</div><div>   longer than the mask an error comes back (EINVAL).</div><div> - Relative format - a concatenation (done with ',') of the terms</div><div>   +<bitnr>[-<bitnr>] or -<bitnr>[-<bitnr>]. <bitnr> may be any</div><div>   valid number (hex, decimal or octal) in the range 0...255.</div><div>   Here are some examples:</div><div>     "+0-15,+32,-128,-0xFF"</div><div>     "-0-255,+1-16,+0x128"</div><div><br></div><div>Signed-off-by: Harald Freudenberger <<a href="mailto:freude@linux.ibm.com">freude@linux.ibm.com</a>></div><div>Signed-off-by: Martin Schwidefsky <<a href="mailto:schwidefsky@de.ibm.com">schwidefsky@de.ibm.com</a>></div><div><br></div><div>---</div><div><br></div><div><a href="https://github.com/torvalds/linux/commit/3d8f60d38e249f989a7fca9c2370c31c3d5487e1">https://github.com/torvalds/linux/commit/3d8f60d38e249f989a7fca9c2370c31c3d5487e1</a></div></div></div>