From owner-svn-src-head@freebsd.org Thu Dec 29 18:02:29 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CF22CC966F6; Thu, 29 Dec 2016 18:02:29 +0000 (UTC) (envelope-from mjguzik@gmail.com) Received: from mail-wj0-x242.google.com (mail-wj0-x242.google.com [IPv6:2a00:1450:400c:c01::242]) (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)) by mx1.freebsd.org (Postfix) with ESMTPS id 7189E1038; Thu, 29 Dec 2016 18:02:29 +0000 (UTC) (envelope-from mjguzik@gmail.com) Received: by mail-wj0-x242.google.com with SMTP id qs7so20744879wjc.1; Thu, 29 Dec 2016 10:02:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=VKzF+RRrmNeMDMt0RHM7aLXIVKET5scTKxT26mHUN2Y=; b=ERXT8lD3eCMfUwNUNZs62APACFL2y62f8oRYkIT2sLzLiXBxvNAlFQNrxq0pEo9RZD L7lj1aZqNgoXaV0dmnl3YcKJqOtCgHCB2QOcBkfypyO6FTLwRIf1e9ZoAarrP/qarBGt T5QifcLO25FrWU5AyePH5gGqfR1A3T51nvDNQfQNrMkvY6oz525w4+KwBiuRXoZemj71 vdbu0KrjcTLUMFEBwO1u5vaj5VIyXeAb0CSDAg6FSLyEV2LkUf651YTf6NrOOuvavuua BHTW6GaTwzFoagle5c3jyQvPvtLsFu5inQrOBsS1tvzJ2nvZqv0Ix5nvfdUXNYOr15d+ lSZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=VKzF+RRrmNeMDMt0RHM7aLXIVKET5scTKxT26mHUN2Y=; b=CkBeqDN2BPS8QdGUCje2Hx89IxrIonFxTu4ibylDJfTOn57UMtc9s1SlxpiRqKw91d WBQKNhz5R/kY8lkn6nxWxQlO5zn/WmSFFcrFc7gZ1xslC3x7UxB0BAU96QzkOKHJmB8M QExPlur1QCPmzFC5zGXIUjI1rxZllH7X/aS8McHQNaXGOaK4HbsYckhKYT6VAsblGNgw Zda3/vjGlfV1mhJd/ANxbQE/UOHScJXX2fr80eq8tmqwz42So44O8QdMavliiPRFVchh WEbz5cjQ4x7ZBnePZV5QepkvXauVMuJqucAmuLIqlohrDj89DHy600vM3h191TtXYDTe Ei7Q== X-Gm-Message-State: AIkVDXKEf2q4l5U3l/JyWgfcwkGCgYLIe6z1jxSahCNUIHhwZh/NR1wK50zx7mWEGiQtgw== X-Received: by 10.194.69.230 with SMTP id h6mr43158332wju.63.1483034547252; Thu, 29 Dec 2016 10:02:27 -0800 (PST) Received: from dft-labs.eu (n1x0n-1-pt.tunnel.tserv5.lon1.ipv6.he.net. [2001:470:1f08:1f7::2]) by smtp.gmail.com with ESMTPSA id g184sm66350143wme.23.2016.12.29.10.02.25 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Thu, 29 Dec 2016 10:02:26 -0800 (PST) Date: Thu, 29 Dec 2016 19:02:24 +0100 From: Mateusz Guzik To: Alexander Motin Cc: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r310778 - head/sys/cam/ctl Message-ID: <20161229180223.GD29676@dft-labs.eu> References: <201612291509.uBTF9YxM055182@repo.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <201612291509.uBTF9YxM055182@repo.freebsd.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 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, 29 Dec 2016 18:02:29 -0000 On Thu, Dec 29, 2016 at 03:09:34PM +0000, Alexander Motin wrote: > Author: mav > Date: Thu Dec 29 15:09:34 2016 > New Revision: 310778 > URL: https://svnweb.freebsd.org/changeset/base/310778 > > Log: > Improve use of I/O's private area. > > - Since I/Os are allocates from per-port pools, make allocations store > pointer to CTL softc there, and use it where needed instead of global. > - Created bunch of helper macros to access LUN, port and CTL softc. > This fails to build with: sys/modules/ctl/../../cam/ctl/ctl.c:12522:27: error: member reference base type 'void' is not a structure or union mtx_assert(&CTL_SOFTC(io)->ctl_lock, MA_NOTOWNED); Looks like thep roblem is that CTL_SOFTC indeed does not cast and returns void instead: +#define CTL_SOFTC(io) ((io)->io_hdr.ctl_private[CTL_PRIV_LUN].ptrs[1]) -- Mateusz Guzik