From patchwork Mon Oct 17 19:11:17 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 9380293 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 1B7EA60487 for ; Mon, 17 Oct 2016 19:11:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F31AC28567 for ; Mon, 17 Oct 2016 19:11:53 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E7ABC28FE7; Mon, 17 Oct 2016 19:11:53 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8CB2128567 for ; Mon, 17 Oct 2016 19:11:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964844AbcJQTLw (ORCPT ); Mon, 17 Oct 2016 15:11:52 -0400 Received: from bombadil.infradead.org ([198.137.202.9]:56852 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964808AbcJQTLv (ORCPT ); Mon, 17 Oct 2016 15:11:51 -0400 Received: from [83.175.99.196] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.85_2 #1 (Red Hat Linux)) id 1bwDKA-0006XF-NZ for linux-rdma@vger.kernel.org; Mon, 17 Oct 2016 19:11:51 +0000 From: Christoph Hellwig To: linux-rdma@vger.kernel.org Subject: [PATCH 08/13] ibacm: remove no-op osd_init/osd_close macros Date: Mon, 17 Oct 2016 21:11:17 +0200 Message-Id: <1476731482-26491-9-git-send-email-hch@lst.de> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1476731482-26491-1-git-send-email-hch@lst.de> References: <1476731482-26491-1-git-send-email-hch@lst.de> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Christoph Hellwig --- ibacm/linux/osd.h | 3 --- ibacm/prov/acmp/src/acmp.c | 3 --- ibacm/src/acm.c | 3 --- ibacm/src/acme.c | 8 +------- 4 files changed, 1 insertion(+), 16 deletions(-) diff --git a/ibacm/linux/osd.h b/ibacm/linux/osd.h index 12877f4..ee582bb 100644 --- a/ibacm/linux/osd.h +++ b/ibacm/linux/osd.h @@ -112,9 +112,6 @@ static inline int event_wait(event_t *e, int timeout) return ret; } -#define osd_init() 0 -#define osd_close() - static inline uint64_t time_stamp_us(void) { struct timeval curtime; diff --git a/ibacm/prov/acmp/src/acmp.c b/ibacm/prov/acmp/src/acmp.c index 1f3aeef..4cda359 100644 --- a/ibacm/prov/acmp/src/acmp.c +++ b/ibacm/prov/acmp/src/acmp.c @@ -2941,9 +2941,6 @@ static void acmp_log_options(void) static void __attribute__((constructor)) acmp_init(void) { - if (osd_init()) - return; - acmp_set_options(); acmp_log_options(); diff --git a/ibacm/src/acm.c b/ibacm/src/acm.c index 056824d..912d563 100644 --- a/ibacm/src/acm.c +++ b/ibacm/src/acm.c @@ -3076,9 +3076,6 @@ int main(int argc, char **argv) if (daemon) daemonize(); - if (osd_init()) - return -1; - acm_set_options(); if (acm_open_lock_file()) return -1; diff --git a/ibacm/src/acme.c b/ibacm/src/acme.c index c5be0a3..f2c9348 100644 --- a/ibacm/src/acme.c +++ b/ibacm/src/acme.c @@ -985,14 +985,10 @@ static void parse_perf_arg(char *arg) int main(int argc, char **argv) { - int op, ret; + int op, ret = 0; int make_addr = 0; int make_opts = 0; - ret = osd_init(); - if (ret) - goto out; - while ((op = getopt(argc, argv, "e::f:s:d:vcA::O::D:P::S:C:V")) != -1) { switch (op) { case 'e': @@ -1068,8 +1064,6 @@ int main(int argc, char **argv) if (!ret && make_opts) ret = gen_opts(); - osd_close(); -out: if (verbose || !(make_addr || make_opts) || ret) printf("return status 0x%x\n", ret); return ret;