From owner-svn-src-head@freebsd.org Mon Aug 7 21:37:58 2017 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 81CD8DCA74F for ; Mon, 7 Aug 2017 21:37:58 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-it0-x233.google.com (mail-it0-x233.google.com [IPv6:2607:f8b0:4001:c0b::233]) (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 3E29D84866 for ; Mon, 7 Aug 2017 21:37:58 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-it0-x233.google.com with SMTP id 77so9791055itj.1 for ; Mon, 07 Aug 2017 14:37:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=NI8SPRm+PsybPL/kAX0p0cNCCji6y3xyJswDwJNTVac=; b=vOIomLcSp2yrp+UN9u/QEofg+M7T9X/u4YEvt7+gp1ymHo5hZMeXuR0l+ssV5mVx+u WTSKjg7lL/Ytzu3CsPSRvzNTrbWHQtuTYh5VIiAyDTNwmkcM4cYbjQZ1zjxHGAoPPKvv HqVHvjvNtnYP+jE4dEnQQyrfDEgjr2kpmCTrMVasou++WsruT0GmOvSkQ7By0Is1XssM kCvDCgiZl1Sm3Lzd6mTaw1uehHe22jqPCx8zE0Wy3ZE5oVUj/LOHT+QxYnM6eS27tiE5 gg6V66YC31jKBKwfWKVVI5pNLlYm+smcWw8RDlJHO/wb3eHIVnLfRTw0leFkaO7234kh pT4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=NI8SPRm+PsybPL/kAX0p0cNCCji6y3xyJswDwJNTVac=; b=NAHIhPe7IDg0vwh5dWRKxfilwOhAYTOum4vx3h0v79mC6XpUSfkLCsnoa9GQaaIZZN E2H0RpJXoOOmQHVKsZYEIno2XEQVViTfXQwjt/KrnYpx9UUPNvKHrSnDp2vEVJfLHiPb Ysl1ZLpKdXimuU/QmMQAxINMwMPuzrl8pTNSPQX5xC+XNAaqvTq3AzIUSCuuSPCMsFI0 xDjVSKboh31g3RSsL0a4WSkxzoHne8mFCPixGDA7eiruuYRC6Pm7PBCAkRjI4fgQiKiF YH0VHtnlfhmLNHH4gQ8CHlP8XYH7Ww2eMAVOsuiasKccnFrnJHsD9m1AZLxYK+pNmXJL kVYA== X-Gm-Message-State: AIVw110vQ+DqTB6CeCVvUJsNtNAGquHQKecKwoAZbgDWi+JVCLb0wy2J bD+vq3IHCFKlZU26kyvNyIy7zI+NC4Cr X-Received: by 10.36.68.193 with SMTP id o184mr2089095ita.59.1502141877712; Mon, 07 Aug 2017 14:37:57 -0700 (PDT) MIME-Version: 1.0 Sender: wlosh@bsdimp.com Received: by 10.79.10.71 with HTTP; Mon, 7 Aug 2017 14:37:57 -0700 (PDT) X-Originating-IP: [2603:300b:6:5100:f809:2296:13f6:2a42] In-Reply-To: <20170807212937.GJ1700@kib.kiev.ua> References: <201708072112.v77LCSxL001381@repo.freebsd.org> <20170807212937.GJ1700@kib.kiev.ua> From: Warner Losh Date: Mon, 7 Aug 2017 15:37:57 -0600 X-Google-Sender-Auth: _YaedL6OTiTGDFf4VI-Q-BhVgXU Message-ID: Subject: Re: svn commit: r322196 - head/sys/geom To: Konstantin Belousov Cc: Warner Losh , src-committers , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.23 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: Mon, 07 Aug 2017 21:37:58 -0000 On Mon, Aug 7, 2017 at 3:29 PM, Konstantin Belousov wrote: > On Mon, Aug 07, 2017 at 09:12:28PM +0000, Warner Losh wrote: > > + LIST_FOREACH(gap, &pp->geom->aliases, ga_next) { > > + error = make_dev_alias_p(MAKEDEV_CHECKNAME | > MAKEDEV_WAITOK, &adev, dev, > > + "%s", gap->ga_alias); > > + if (error) { > > + printf("%s: make_dev_alias_p() failed (name=%s, > error=%d)\n", > > + __func__, gap->ga_alias, error); > > + continue; > > + } > > + adev->si_flags |= SI_UNMAPPED; > Why do you set the flag unconditionally ? Because it's set for "dev" unconditionally and the old compat code did it too... > + adev->si_iosize_max = dev->si_iosize_max; > > + adev->si_drv2 = dev->si_drv2; > And what are you trying to do by these initializations, including the > si_flags adjustment ? > The old (ad->ada) compat code set them. Though to be honest, I didn't drill down into the devfs code to see if that as still relevant. It sounds like maybe not relevant... > Aliases cause creation of symlinks in the devfs populate loop, which > makes it impossible to access the alias cdevs. > True enough. If so, do you think these adjustments to adev can just be removed entirely? A quick look in devfs code suggests that it doesn't matter since, as you point out, it's a symlink not a new, different node. Thanks for the feedback. Warner