Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp6649979iob; Wed, 11 May 2022 02:15:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz0OZESK0+WwHKRt5n9s0/PLypVTuJfQkXPdidOrcYhdtpXu+bGMxgY97603veiZDPHau4q X-Received: by 2002:a17:902:7104:b0:15e:ddb8:199 with SMTP id a4-20020a170902710400b0015eddb80199mr24684007pll.80.1652260528971; Wed, 11 May 2022 02:15:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652260528; cv=none; d=google.com; s=arc-20160816; b=Qd+PqzLUwutPB0uPvLMBD7xTx+sWMsrQH2PUxa2aux2EPJmil5gvsXE2Wxg5iVVgNn +bZCH10jqVs1vvtw++JMHqZG8EMYDunruxWFGK+3eyASLHsKvC/U8GZ/AsYWe0zloJfa BKxyAQi7z4BHE4R31jIgdl46nmvWIH6ND4h6wEj12Z2AmLuZp4Q+tLqbMf9Ay3Gg+yFK NvZkluxYQSkFZ2bioFQyj8FriQP2W924iZVYS69MaVnM0QWZzABqKyj7wBkUAhK/8Y6w Eni0ra0OjI8an5qDXuOElcyoHNp2Q9fX9gWMEWAPoRMK1Hr/oSqNDxuZgzxOtSXPXhfQ uyjg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:date:message-id:user-agent:cc:to:references :in-reply-to:from:subject:content-transfer-encoding:mime-version :dkim-signature; bh=u8err+5nnX5cXLz21AgYwxbLqV/AxRHORjnBYGnhxWk=; b=TiVSN0m6Ma8Xps6KNC+hbjWt90py8hKL5aX0xMQGiPDTDASQQgVCSxa3tjofO9v4d4 dtNhkh+Y2K0hgQ02EP4MNm1ln5JHfUY+W/Ja8xYOjEE5MOT8CQkeiXRU0NhfbWXRiyB2 o9bIydwsAQfzKGF+jJBB4aZqQkUz39YtYlX8TQVRwu0ktGV857VBE8OQwCninHo3iYwa 9L41I8mrwmUti46vmn/77PDUYLhgf7/k7X3KVusXPctMaeqHXW8cvVHbVrPIVfsnFRPN oeadxPBqer0y56TLyIRC2NXp2mg44dZz/m70Ok8NwQ6QlTvE9mhPaATivhEVIEgStc6d DXzw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=cSB4IaOn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id pc8-20020a17090b3b8800b001cd51f48295si2325057pjb.174.2022.05.11.02.15.15; Wed, 11 May 2022 02:15:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=cSB4IaOn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240802AbiEKFdM (ORCPT + 99 others); Wed, 11 May 2022 01:33:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49976 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229532AbiEKFdJ (ORCPT ); Wed, 11 May 2022 01:33:09 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 89FA93DA54; Tue, 10 May 2022 22:33:08 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 2D0DB616D7; Wed, 11 May 2022 05:33:08 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0C883C385DB; Wed, 11 May 2022 05:33:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1652247187; bh=NGoQcJ+iAsisQ8f+zssQ2YRnfJafdWbUwxc1jht6wNA=; h=Subject:From:In-Reply-To:References:To:Cc:Date:From; b=cSB4IaOnU68YF8oFv+bQqP4IiBCvoQJF27pXbBm7YR5F/jxe0zMv0GrC4hE762vYm 7gfBSxFgQbWdZFr8p8ItlLSTB/wp0t/3HdlhAGWAgm+kLV65+9BSXyXEqckrr4Aqxr PjKGBj44lQ4pQLMBHlgT0SF+Wfcc0ZU+wmhyCOGSQXQYep4MbrbM2Ou4qu/4ejNupQ nbYUTTDtq/84GOzULUkRBSbd1qXrBNp7igdsmsNtansWVvzghdS6xWu9qKjfhLbNQH CcLFkW+EB3lJFozt1YMFSMHoV6hTI4jj9Bl2ZJFKHvnYpycUuTTWj1yQLoODaXFUFf iJOtghB0hljoA== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: Re: [PATCH v6] wfx: use container_of() to get vif From: Kalle Valo In-Reply-To: <20220506170046.GA1297231@jaehee-ThinkPad-X1-Extreme> References: <20220506170046.GA1297231@jaehee-ThinkPad-X1-Extreme> To: Jaehee Park Cc: =?iso-8859-1?q?J=E9r=F4me?= Pouiller , "David S. Miller" , Jakub Kicinski , Paolo Abeni , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-staging@lists.linux.dev, outreachy@lists.linux.dev, Jaehee Park , Stefano Brivio User-Agent: pwcli/0.1.0-git (https://github.com/kvalo/pwcli/) Python/3.7.3 Message-ID: <165224718272.19198.8867712647289084011.kvalo@kernel.org> Date: Wed, 11 May 2022 05:33:04 +0000 (UTC) X-Spam-Status: No, score=-7.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Jaehee Park wrote: > Currently, upon virtual interface creation, wfx_add_interface() stores > a reference to the corresponding struct ieee80211_vif in private data, > for later usage. This is not needed when using the container_of > construct. This construct already has all the info it needs to retrieve > the reference to the corresponding struct from the offset that is > already available, inherent in container_of(), between its type and > member inputs (struct ieee80211_vif and drv_priv, respectively). > Remove vif (which was previously storing the reference to the struct > ieee80211_vif) from the struct wfx_vif, define a function > wvif_to_vif(wvif) for container_of(), and replace all wvif->vif with > the newly defined container_of construct. > > Signed-off-by: Jaehee Park Patch applied to wireless-next.git, thanks. 2c33360bce6a wfx: use container_of() to get vif -- https://patchwork.kernel.org/project/linux-wireless/patch/20220506170046.GA1297231@jaehee-ThinkPad-X1-Extreme/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches