* @brief Set the devclass of a device and mark the devclass fixed. * @see device_set_devclass() */
| 2757 | * @see device_set_devclass() |
| 2758 | */ |
| 2759 | int |
| 2760 | device_set_devclass_fixed(device_t dev, const char *classname) |
| 2761 | { |
| 2762 | int error; |
| 2763 | |
| 2764 | if (classname == NULL) |
| 2765 | return (EINVAL); |
| 2766 | |
| 2767 | error = device_set_devclass(dev, classname); |
| 2768 | if (error) |
| 2769 | return (error); |
| 2770 | dev->flags |= DF_FIXEDCLASS; |
| 2771 | return (0); |
| 2772 | } |
| 2773 | |
| 2774 | /** |
| 2775 | * @brief Query the device to determine if it's of a fixed devclass |
nothing calls this directly
no test coverage detected