| 34 | } |
| 35 | |
| 36 | bool cbmem_drv_init(enum cbmem_drv_backend_type backend, bool writeable) |
| 37 | { |
| 38 | if (backend != CBMEM_DRV_BACKEND_ANY) |
| 39 | return init_specific_backend(backend, writeable); |
| 40 | |
| 41 | /* First try SYSFS backend as it's more secure. */ |
| 42 | if (!init_specific_backend(CBMEM_DRV_BACKEND_SYSFS, writeable)) |
| 43 | return init_specific_backend(CBMEM_DRV_BACKEND_DEVMEM, writeable); |
| 44 | |
| 45 | return true; |
| 46 | } |
| 47 | |
| 48 | void cbmem_drv_terminate(void) |
| 49 | { |
no test coverage detected