Vaibhav Jain <vaib...@linux.vnet.ibm.com> writes: > Michael Ellerman <m...@ellerman.id.au> writes: >> <snip> <snip> >> >> What would be nice is if we keep that behaviour, but any action you take >> in xmon that requires xmon to remain resident, ie. setting a breakpoint, >> calls a function which makes sure xmon_on = true and if it wasn't prints >> a nice message saying "Turning xmon on due to breakpoint insertion" or >> something.
> That makes sense to me and sounds workable. However we already have a > debugfs interface to enable/disable xmon debugger hook. I can also tweak > this interface to also register the sysrq key when xmon is enabled. This > should provide the user the ability to still use xmon if they want to > after the system has booted with xmon=off. I agree that sounds sensible, but it has one fatal flaw IMO. Currently you can boot a box with XMON_DEFAULT=n, and it will crash dump and so on, but if the box gets stuck you can jump on the console and drop into xmon with sysrq-x. If we additionally require xmon to be enabled via debugfs every boot that will break the above use case, and I don't want to do that. So in short I think I like my idea better :) cheers