Kdrefactor

I think this body of `if` should be extracted as module same as `door.h`