From owner-svn-src-head@freebsd.org Thu Jun 14 00:03:35 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2D7721004470; Thu, 14 Jun 2018 00:03:34 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "smtp.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2538183EF4; Thu, 14 Jun 2018 00:03:34 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: from mail-it0-f50.google.com (mail-it0-f50.google.com [209.85.214.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) (Authenticated sender: mmacy) by smtp.freebsd.org (Postfix) with ESMTPSA id E08939DF7; Thu, 14 Jun 2018 00:03:33 +0000 (UTC) (envelope-from mmacy@freebsd.org) Received: by mail-it0-f50.google.com with SMTP id j135-v6so6364738itj.1; Wed, 13 Jun 2018 17:03:33 -0700 (PDT) X-Gm-Message-State: APt69E3aLzxwSjhx0n1IUW1tova0qDzKr7cTqmjNz6SLOyQ5mTDeDRe7 MqGVzfcgrIH9Nf+k7lcsVtqIN3Go4RWn41uJ3NA= X-Google-Smtp-Source: ADUXVKKp11+qZCqiBS0ZphTcy3xucW+zGcMgTtbOY0q/CDa/ytDEIyJO3wqZ4h7S1vTPXPSb5TZfc4jgm/LhT7kvBvs= X-Received: by 2002:a24:6c8a:: with SMTP id w132-v6mr248860itb.4.1528934613342; Wed, 13 Jun 2018 17:03:33 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a02:8cd:0:0:0:0:0 with HTTP; Wed, 13 Jun 2018 17:03:32 -0700 (PDT) In-Reply-To: References: <201806132330.w5DNUsrE043573@repo.freebsd.org> From: Matthew Macy Date: Wed, 13 Jun 2018 17:03:32 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: svn commit: r335094 - head/sys/ofed/drivers/infiniband/core To: Ryan Libby Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org, bde@freebsd.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 Jun 2018 00:03:36 -0000 On Wed, Jun 13, 2018 at 4:47 PM, Ryan Libby wrote: > On Wed, Jun 13, 2018 at 4:30 PM, Matt Macy wrote: >> Author: mmacy >> Date: Wed Jun 13 23:30:54 2018 >> New Revision: 335094 >> URL: https://svnweb.freebsd.org/changeset/base/335094 >> >> Log: >> fix OFED build after r335053 >> >> Modified: >> head/sys/ofed/drivers/infiniband/core/ib_user_mad.c >> >> Modified: head/sys/ofed/drivers/infiniband/core/ib_user_mad.c >> ============================================================================== >> --- head/sys/ofed/drivers/infiniband/core/ib_user_mad.c Wed Jun 13 23:19:54 2018 (r335093) >> +++ head/sys/ofed/drivers/infiniband/core/ib_user_mad.c Wed Jun 13 23:30:54 2018 (r335094) >> @@ -130,7 +130,8 @@ struct ib_umad_packet { >> >> static struct class *umad_class; >> >> -static const dev_t base_dev = MKDEV(IB_UMAD_MAJOR, IB_UMAD_MINOR_BASE); >> +#define IBMKDEV(x, y) (((dev_t)(x) << 32) | (unsigned)(y)) >> +static const dev_t base_dev = IBMKDEV(IB_UMAD_MAJOR, IB_UMAD_MINOR_BASE); >> >> static DEFINE_SPINLOCK(port_lock); >> static DECLARE_BITMAP(dev_map, IB_UMAD_MAX_PORTS); >> > > The scheme for major/minor encoding is different as of r335053. Won't > that matter? Yes. > In sys/ofed/drivers/infiniband/core/{ib_ucm.c,ib_uverbs_main.c} the > pattern is to #define the MKDEV(). Following that would in > ib_user_mad.c would also resolve this. Or makedev could be > re-macroized with the new scheme. That's probably the best course of action. Will follow up.