From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932222AbbCaBiE (ORCPT ); Mon, 30 Mar 2015 21:38:04 -0400 Received: from mga01.intel.com ([192.55.52.88]:11887 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932111AbbCaBhg (ORCPT ); Mon, 30 Mar 2015 21:37:36 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.11,498,1422950400"; d="scan'208";a="700516622" From: Sudeep Dutt To: Greg Kroah-Hartman Cc: Arnd Bergmann , Jonathan Corbet , linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, Dave Jiang , Nikhil Rao , Ashutosh Dixit , Sudeep Dutt Subject: [PATCH char-misc-next v4 13/13] misc: mic: add support for loading/unloading SCIF driver Date: Mon, 30 Mar 2015 18:36:27 -0700 Message-Id: X-Mailer: git-send-email 1.8.2.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org modprobe SCIF driver upon start and remove it upon unload Reviewed-by: Nikhil Rao Reviewed-by: Ashutosh Dixit Signed-off-by: Sudeep Dutt --- Documentation/mic/mpssd/mpss | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git a/Documentation/mic/mpssd/mpss b/Documentation/mic/mpssd/mpss index cacbdb0..582aad4 100755 --- a/Documentation/mic/mpssd/mpss +++ b/Documentation/mic/mpssd/mpss @@ -35,6 +35,7 @@ exec=/usr/sbin/mpssd sysfs="/sys/class/mic" +mic_modules="mic_host mic_x100_dma scif" start() { @@ -48,18 +49,15 @@ start() fi echo -e $"Starting MPSS Stack" - echo -e $"Loading MIC_X100_DMA & MIC_HOST Modules" + echo -e $"Loading MIC drivers:" $mic_modules - for f in "mic_host" "mic_x100_dma" - do - modprobe $f - RETVAL=$? - if [ $RETVAL -ne 0 ]; then - failure - echo - return $RETVAL - fi - done + modprobe -a $mic_modules + RETVAL=$? + if [ $RETVAL -ne 0 ]; then + failure + echo + return $RETVAL + fi # Start the daemon echo -n $"Starting MPSSD " @@ -170,8 +168,8 @@ unload() stop sleep 5 - echo -n $"Removing MIC_HOST & MIC_X100_DMA Modules: " - modprobe -r mic_host mic_x100_dma + echo -n $"Removing MIC drivers:" $mic_modules + modprobe -r $mic_modules RETVAL=$? [ $RETVAL -ne 0 ] && failure || success echo -- 1.8.2.1