Fix C FB viewer

* Check if kernel driver is attached before detaching