From 4bb4f65cb29dd2c10595f780afa4f1d10b8d99ae Mon Sep 17 00:00:00 2001 From: Ian Abbott Date: Tue, 9 Dec 2008 11:07:22 +0000 Subject: [PATCH] Make comedi_auto_config() succeed when auto-configuration disabled. --- comedi/drivers.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/comedi/drivers.c b/comedi/drivers.c index bb9b4828..66bd91cf 100644 --- a/comedi/drivers.c +++ b/comedi/drivers.c @@ -799,8 +799,10 @@ int comedi_auto_config(struct device *hardware_device, const char *board_name, c int retval; unsigned *private_data = NULL; - if(!comedi_autoconfig) - return -ENODEV; + if(!comedi_autoconfig) { + dev_set_drvdata(hardware_device, NULL); + return 0; + } minor = comedi_alloc_board_minor(hardware_device); if(minor < 0) return minor; -- 2.26.2