That's exactly how a bunch of 680x0-based drivers do it.