Received: by 2002:ab2:3b09:0:b0:1ed:14ea:9113 with SMTP id b9csp153097lqc; Thu, 29 Feb 2024 13:06:37 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVVwHvl86NCW5gBPK7y9LU9R3AHqhvHUPKe7bwgAD4mgscGtIc60kntVDibxf0z/Ds97K+CBzrmbmCMU31OKtNeGdPfVWMCtacZjhAmXA== X-Google-Smtp-Source: AGHT+IE8fj8sAvBRmxbEFOpK9knE8xzG/zfMikicvNibyg9aaMM48aW1kg+2yXLYiMyOunlf1yvc X-Received: by 2002:a05:6102:c49:b0:470:a136:5c00 with SMTP id y9-20020a0561020c4900b00470a1365c00mr4097605vss.17.1709240796912; Thu, 29 Feb 2024 13:06:36 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709240796; cv=pass; d=google.com; s=arc-20160816; b=qJ4FnEC0c4RsIQBrTdzxUWL6QpegOe6+S4+dlY92wom1WUsnvLifB9k66Ey6wXux0B x3OVR/cwhq6IcCFgLlPwXWxOxYaR+57NXXYNy5YadKkp3vRneMJrzQimy/d4BBb1mktE 5NeYp/+mvPQb4SgFIUXhpWhjF6faetT6OHHXy1UStPoPVxScq0tHaik0hNaM9CC1ZWt4 GTGSwRlnEqLhiIdfwD7Sf8XV9esdNxQY2wIygyGGmrKnuBZb0da28QcoDIzT/qdWfdRj tt+vfQ+kHWG5PdMb8Qdcr2HBuq8C4gqVo7VOPT4hxoaY9LpCqDB90rvasLye3OmnMUu8 89Rg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=oXClQocKFU332MGv51HiVp3gBqp0PjGOnlHuqmYRRz8=; fh=J/wHVCq0rCb6RRy7BbsQNQv1ytcOSTWeaEE/l1b4/DY=; b=nCCFXO1vLuCPkuQKGojNNjzooE6jvfUEg49+pspjxIdX3NYb8r3vCKrcFb3Z8J2+F5 kW5EqD+UMIYvBRBGiikk3FiptQuhS98Kfja37hq5RblD1e2hSlsxe1IoEC5Je+TfnVIj TaXES8ypS2LsDdcojC1g3ouedGH+1yO9hUfTWsHXCfn1jFl8x/G7dAJUr8iVKPrfTilS ZRUANUsp/u6OwWSi4FDag5bo2eVB+mfunTud3klWAvVFHjPPrt1HL5AnD0aslnrq6iET IHaAr/n6FDh8h/15KT6oWc6kmuR9igd5w8cRISU6gf7C4pYS9ovgpLVclj5Ds8BfEAqS uxgg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="floC//zT"; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-87535-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-87535-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id e26-20020a056102225a00b0047277e5969fsi344936vsb.569.2024.02.29.13.06.36 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 29 Feb 2024 13:06:36 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-87535-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="floC//zT"; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-87535-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-87535-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 9DBF21C22F7B for ; Thu, 29 Feb 2024 21:06:36 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6DCAF14565D; Thu, 29 Feb 2024 20:56:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="floC//zT" Received: from mail-il1-f172.google.com (mail-il1-f172.google.com [209.85.166.172]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DC659142905 for ; Thu, 29 Feb 2024 20:56:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.166.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709240163; cv=none; b=cFCN5NID6Q/gwEi0WdqfSh1zTG7qQKHmM7SzZwJGSacwEnCkLkJjMR3fPS/eZrkpnAD6yk6VLWEAZwM6CdAeYx7FevnV+lOZlUra1dAehCDD1lB4ALeBrnbArE1V/yQq4pWAP3lpZzU/tFGwM+xLlhvrZH7Zf7GnsLXxGY16TiQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709240163; c=relaxed/simple; bh=CkoPh+10iHxKZkJwRU1etR8ewLdQSrZpBt//3BLiDzg=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=K/hGDJt7woLFTcsZzfWynB4dfD5zSPEPTQ9SYTdqhe68Ja3qVt4P0+qvIawpyYUIVj4Lgvp86IZPhTD0I+XTz8TcsQDoN3ed8yPmiEfVfrQsU+yEeQGMSmUQBuIaSC+PW/ght9bqRUyC6rfLaGbzQepL5c1fHBHEcD15Dina7fc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=floC//zT; arc=none smtp.client-ip=209.85.166.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-il1-f172.google.com with SMTP id e9e14a558f8ab-36524116e30so5755895ab.0 for ; Thu, 29 Feb 2024 12:56:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1709240160; x=1709844960; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=oXClQocKFU332MGv51HiVp3gBqp0PjGOnlHuqmYRRz8=; b=floC//zTAZLTBCKflTu7/hlDyrLS+d7K9VP895M9QkjkQ4OS+7uBKi+sn9o2+Fgs2c 03TMN6Z65gm7ctHosI9mChf6Mdlu7syY55eeNH6SQoQkcHeR85mng387f+ZqxSoKdt/G 6YrOapPRwrEs15LacMGxO7Njh/DHekDvA5GTY2P3PJHhw4Fd0wZEKL3OBTMirY1+i4Y5 FRC865nqEnZhwA1yVlnFAhfr6qOu+QA5kfEe9C3GCjKPpoH3qoOgbCsPMsNRkIjuTect C1z4cRpgPv1jokZyvmhYR63jvOtU/kDrMGSOBnOT88fT1utfvbooloySjwrdIVqNooni NapQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709240160; x=1709844960; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=oXClQocKFU332MGv51HiVp3gBqp0PjGOnlHuqmYRRz8=; b=uUWy366rt/AcJ8+dx/KQnDMU6whjkKKRcM3op0vYqqR7x2A1+nL1dOoFn72GCjVvJg OiGurq0KV25AbO66eNcrwRBivzaUuLpTfLVJIBe8KjKX0t0DEPpqY/ZWHBy41uG8OXkw oocZEP237iKNLeLm84QjpEh4E18t9oM3P5IjTIFZc0kBsRUt7FQv7mMQvjZZlpR8fqc3 cK+Wmu7olqjNNzRpu6DCMzWGYNb69XyQsbThLTDz49qbN81P83yN+sV7PCZtFUZTQUyS 2Xcb1EuUoamTH9okv9t4YS5LP5uVlOlnkS52C8IYx7w7fcVZ5TapOTO4uYoGPPqqYMH0 RqIA== X-Forwarded-Encrypted: i=1; AJvYcCW3aFqvs9h6DXBLlonPTqTT4i3k55TdXizF9NSJkwXaqH6HHu/N9yVlyRktvmaIzLMuPPKq53BVf6wFfh8mJN9k68TfXBOfg1LnAzgo X-Gm-Message-State: AOJu0Yzqt1ODju3vAXpHMmpn4Htb/QTUU5S60xvRAeQLZ+T63nQ4SmAr PrSfY/hy+OzAvbg9amDCGACTdIoYyYp8VagZDN/zFuqUL6/WaY2SWdCc669ehTQ= X-Received: by 2002:a05:6e02:b43:b0:365:23fe:12fb with SMTP id f3-20020a056e020b4300b0036523fe12fbmr258132ilu.11.1709240160006; Thu, 29 Feb 2024 12:56:00 -0800 (PST) Received: from localhost.localdomain (c-73-228-159-35.hsd1.mn.comcast.net. [73.228.159.35]) by smtp.gmail.com with ESMTPSA id h14-20020a056e020d4e00b003658fbcf55dsm521551ilj.72.2024.02.29.12.55.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 29 Feb 2024 12:55:59 -0800 (PST) From: Alex Elder To: davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com Cc: mka@chromium.org, andersson@kernel.org, quic_cpratapa@quicinc.com, quic_avuyyuru@quicinc.com, quic_jponduru@quicinc.com, quic_subashab@quicinc.com, elder@kernel.org, netdev@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH net-next 0/7] net: ipa: simplify device pointer access Date: Thu, 29 Feb 2024 14:55:47 -0600 Message-Id: <20240229205554.86762-1-elder@linaro.org> X-Mailer: git-send-email 2.40.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Outside of initialization, all uses of the platform device pointer stored in the IPA structure determine the address of device structure embedded within the platform device structure. By changing some of the initialization functions to take a platform device as argument we can simplify getting at the device structure address by storing it (instead of the platform device pointer) in the IPA structure. The first two patches split the interrupt initialization code into two parts--one done earlier than before. The next four patches update some initialization functions to take a platform device pointer as argument. And the last patch replaces the platform device pointer with a device pointer, and converts all remaining references to the &ipa->pdev->dev to use ipa->dev. -Alex Alex Elder (7): net: ipa: change ipa_interrupt_config() prototype net: ipa: introduce ipa_interrupt_init() net: ipa: pass a platform device to ipa_reg_init() net: ipa: pass a platform device to ipa_mem_init() net: ipa: pass a platform device to ipa_smp2p_irq_init() net: ipa: pass a platform device to ipa_smp2p_init() net: ipa: don't save the platform device drivers/net/ipa/ipa.h | 5 ++- drivers/net/ipa/ipa_cmd.c | 6 ++-- drivers/net/ipa/ipa_endpoint.c | 29 ++++++++------- drivers/net/ipa/ipa_interrupt.c | 64 +++++++++++++++++++++------------ drivers/net/ipa/ipa_interrupt.h | 22 +++++++++--- drivers/net/ipa/ipa_main.c | 60 +++++++++++++++++++------------ drivers/net/ipa/ipa_mem.c | 37 ++++++++++--------- drivers/net/ipa/ipa_mem.h | 5 ++- drivers/net/ipa/ipa_modem.c | 14 ++++---- drivers/net/ipa/ipa_power.c | 4 +-- drivers/net/ipa/ipa_qmi.c | 10 +++--- drivers/net/ipa/ipa_reg.c | 8 ++--- drivers/net/ipa/ipa_reg.h | 4 ++- drivers/net/ipa/ipa_smp2p.c | 33 ++++++++--------- drivers/net/ipa/ipa_smp2p.h | 7 ++-- drivers/net/ipa/ipa_table.c | 18 +++++----- drivers/net/ipa/ipa_uc.c | 9 +++-- 17 files changed, 193 insertions(+), 142 deletions(-) -- 2.40.1