From 1d70e7f4b0b81e419385e476b5086ecdf02ebec1 Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Wed, 1 Aug 2018 17:41:07 -0600 Subject: [PATCH] Revert "drivers/input/ft5x06.c: Back out part of last PR. I think that is correct to detach the interrupt handler when the drivers is unlinked." No... I was misled. The shutdown function is usually called when the driver is unlinked. But not in this case. In this case, it is simply called when the last reference is closed. And no, you don't want to detach the interrupt handler in that case. My bad. This reverts commit b79e6b9c9a96ba570b83163876ddb05e572515c2. --- drivers/input/ft5x06.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/drivers/input/ft5x06.c b/drivers/input/ft5x06.c index 6891352b7d..8afe629ae0 100644 --- a/drivers/input/ft5x06.c +++ b/drivers/input/ft5x06.c @@ -780,13 +780,6 @@ static void ft5x06_shutdown(FAR struct ft5x06_dev_s *priv) config->clear(config); config->enable(config, false); - - /* Detach the interrupt handler (otherwise, the attach may failed if the - * driver is re-registered, depending upon how the lower-half is - * implemented. - */ - - (void)config->attach(config, NULL, NULL); #endif }