Received: by 2002:a05:6358:111d:b0:dc:6189:e246 with SMTP id f29csp3426544rwi; Tue, 1 Nov 2022 21:29:26 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6kR3rzxcA8FbS15/zaRwOqbhh9YNb9Omdjugjfg5lhOsCckzxIkE6rydRwx7FpWC76+4LW X-Received: by 2002:a17:906:8a57:b0:7ad:69fb:3a with SMTP id gx23-20020a1709068a5700b007ad69fb003amr21460806ejc.179.1667363366647; Tue, 01 Nov 2022 21:29:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1667363366; cv=none; d=google.com; s=arc-20160816; b=kpZWDqfwgeZn8vMzQCpqySMTMwoM2KsHpwVSjZJVCKZaSkFKDaubNzH2c9AvX/wQwS wX7MfYrvb9Hp8BfyuAWG0QV0RxjVaASFYcER79p5lPoO6RIG2uzGTFPJ+9+7RQOCpuFD W68Uuf51RtNou3D+RJR8IvaVCwnoQTBm3dO3pbMSYg4Im9TNAXV49cv/212u4KeqZe3d RNGIBDK3XS7v2HzMwKy4/tiPM9IFtagonyX0jjXncpgrLAueeOqBeVhN1BA/cApKjL11 wr2b0p2D0RJ3XWtNWJbigrjAxyZmUIordPdsNUFSuUsL1La9a0Cq9+GSETw0DOUquRVw 8SBw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=+lPoKYx971f///pdXJJJFh641Mgk8DgJ/Cr5g+6OapQ=; b=XoHqA39gnMqozK3bz8Gbnr3uZtp0r9x1ebiOq1uut3B6QKeFPgsmIWVUikHSvmOtej IM4m9fziDjWexTlMuDBPk5JhWsSl7QnJBO5Gmll2nvQkQ92W9L+uWqq3koJq05lGPvR2 MdW3dSeefmOPN7//snzepiinoQdh6wr4qp4PA4HTyuRvJIdigtkDkSL5xkeG2F03ujjg R5ZbmggeDrKZ33cChcWVTufzP+FixaNbq52uBOtSbqzbQU2YPcll+vsh+0wWedtbtJ8a FlQV7VPGoLqO7xEfMDoRbIbbf+dv6XaXbi83agutiTT3Zyr9BqaQL74ujdZqm8BbkW7d Qb5A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@microchip.com header.s=mchp header.b=NGdzOck6; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=microchip.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ne22-20020a1709077b9600b007addc9401dcsi8885430ejc.484.2022.11.01.21.29.02; Tue, 01 Nov 2022 21:29:26 -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=@microchip.com header.s=mchp header.b=NGdzOck6; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=microchip.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229700AbiKBEOX (ORCPT + 96 others); Wed, 2 Nov 2022 00:14:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51862 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229523AbiKBEOV (ORCPT ); Wed, 2 Nov 2022 00:14:21 -0400 Received: from esa.microchip.iphmx.com (esa.microchip.iphmx.com [68.232.154.123]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B309E2316F; Tue, 1 Nov 2022 21:14:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1667362460; x=1698898460; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=08W5rKKIlMXbts2FT16e7Bj9/VESAyQ7decV9eV/k4A=; b=NGdzOck6yCcD/I1pnC4CkAF2uumlx8j9jkMfS09/rlvK2sxCaNel3bYe l9otSYq1rrTgE62ADAZyiZHohcqkcyEHX8cOJzKmngiwI1+m4roUEsYkD qoYEF5LYUZhyQOPD0PC/CHoliFsNo9zIE/moritUtJv7fZjIp/hOUBk5P 2V1XNFPX1A4cfQqbL0eSXLoZtcrLnYwjCLAXEnQTijngXFFp/dRV2wmE/ ormcyuaDz4VaYupUHDvdi8luBnP+RQ9OyiUFj9OGZU35zfJMUH0D4Dkfc tzq1Vgn+Q0n8t+3kk8qfnR+l3dp3Z/IaSxp5EhTfJqOMn85UIaCE35GIS A==; X-IronPort-AV: E=Sophos;i="5.95,232,1661842800"; d="scan'208";a="184948846" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa2.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 01 Nov 2022 21:14:17 -0700 Received: from chn-vm-ex04.mchp-main.com (10.10.85.152) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.12; Tue, 1 Nov 2022 21:14:17 -0700 Received: from che-lt-i67786lx.microchip.com (10.10.115.15) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server id 15.1.2507.12 via Frontend Transport; Tue, 1 Nov 2022 21:14:13 -0700 From: Rakesh Sankaranarayanan To: , CC: , , , , , , , , , Subject: [PATCH net-next 0/6] net: dsa: microchip: regmap range validation and ksz_pwrite status check for lan937x and irq and error checking updates for ksz series Date: Wed, 2 Nov 2022 09:40:52 +0530 Message-ID: <20221102041058.128779-1-rakesh.sankaranarayanan@microchip.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Spam-Status: No, score=-5.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_PASS,SPF_PASS 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 This patch series include following changes, - add regmap range validation support for lan937x series switches, which will help to avoid access to unused register addresses. - Add KSZ9563 inside ksz_switch_chips. As per current structure, KSZ9893 is reused inside ksz_switch_chips structure, but since there is a mismatch in number of irq's, new member added for KSZ9563 and sku detected based on Global Chip ID 4 Register. Compatible string from device tree mapped to KSZ9563 for spi and i2c mode probes. - Assign device interrupt during i2c probe operation. - Add error checking for ksz_pwrite inside lan937x_change_mtu. After v6.0, ksz_pwrite updated to have return type int instead of void, and lan937x_change_mtu still uses ksz_pwrite without status verification. - Add port_nirq as 3 for KSZ8563 switch family. - Use dev_err_probe() instead of dev_err() to have more standardized error formatting and logging. Rakesh Sankaranarayanan (6): net: dsa: microchip: lan937x: add regmap range validation net: dsa: microchip: add ksz9563 in ksz_switch_ops and select based on compatible string net: dsa: microchip: add irq in i2c probe net: dsa: microchip: add error checking for ksz_pwrite net: dsa: microchip: ksz8563: Add number of port irq net: dsa: microchip: add dev_err_probe in probe functions drivers/net/dsa/microchip/ksz8863_smi.c | 9 +- drivers/net/dsa/microchip/ksz9477.c | 3 +- drivers/net/dsa/microchip/ksz9477_i2c.c | 12 +- drivers/net/dsa/microchip/ksz_common.c | 1794 +++++++++++++++++++++- drivers/net/dsa/microchip/ksz_common.h | 3 + drivers/net/dsa/microchip/ksz_spi.c | 10 +- drivers/net/dsa/microchip/lan937x_main.c | 6 +- 7 files changed, 1816 insertions(+), 21 deletions(-) -- 2.34.1