# Disable device driver



## Phishfry (Nov 2, 2016)

I just got a new toy in and it does not like FreeBSD sdhci(4) driver. It hangs it. The board is an 3.5" SBC and has no SDcard sockets. Maybe it was an option. Anyway, How do I disable a device? I tried this:
`sdhci_load="NO"`
In loader.conf to no avail.


----------



## T-Daemon (Nov 2, 2016)

In this thread there have been proposed two options to disable a driver, one: to rename the kernel module, second: setting an device hint.


----------



## kpa (Nov 2, 2016)

The device.hints(5) method is the recommended one, if you go renaming modules you'll have to keep an eye on the updates if they happen to undo your renames.


----------



## SirDice (Nov 2, 2016)

Also note that renaming modules won't work if the module was built into the kernel. Everything is always built as a module but the devices that are in the kernel config get linked right into it. This might provide some confusion as a module can be both in the kernel and as a loadable file in /boot/kernel/. 

Besides device.hints(5), the other 'proper' solution is to build a custom kernel without the device.


----------



## Phishfry (Nov 2, 2016)

SirDice said:


> the other 'proper' solution is to build a custom kernel without the device


This might be the only option. I tried some hints with no luck. None listed in the sdhci(4) manual.

```
hint.sdhci.0.disabled="1"
hint.sdhci.disabled="1"
hint.sdhci_pci0.disabled="1"
hint.sdhci_pci0.0.disabled="1"
hint.sdhci.0.disabled="YES"
hint.sdhci.disabled="YES"
hint.sdhci_pci0.disabled="YES"
```


----------

