Port-hpcsh archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

hpckbd vs. -Wcast-qual and kernel memory protection



Now that -Wcast-qual hit current, it uncovered an interesting issue.
hpckbd(4) uses pckbd_keydesctab as a based table, patching KB_MACHDEP
entries with information from hpckbdkeymap.h

pckbd_keydesctab is "const" and is placed in the .text - yet hpckbd(4)
patches it successfully. So we have kernel .text kernel-writable.  I
verified it with ddb on hpcsh.  I gather the same is true on other
hpc* ports, or hpckbd(4) would caused access fault.

This looks like something we should fix.

SY, Uwe
-- 
uwe%ptc.spbu.ru@localhost                         |       Zu Grunde kommen
http://www.ptc.spbu.ru/~uwe/            |       Ist zu Grunde gehen



Home | Main Index | Thread Index | Old Index