From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DFEDF70823; Tue, 24 Jun 2025 01:06:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.189 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1750727200; cv=none; b=ho6hNqC6h+nZWCI9Vg+mkylALyMGjkifFTv5dEYSkn4odQLkRxmbrSBcd3QZUStKI1RlasyUaL4FadOClr0JW9ZHxPcoy9/mX4JQSgD2zBtPau4Yt3yP76kfNKlxaikdb3M9if2+z7gZ0yl9MhedQk6jhw8FL+SY+1pv49aHNtQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1750727200; c=relaxed/simple; bh=rGwARyv8tJA7CfEaxg832PKwn6GR6YzUn0fSflXP0Do=; h=Message-ID:Date:MIME-Version:CC:Subject:To:References:From: In-Reply-To:Content-Type; b=MjiJsxUeUv3kNJFmWMpOVW85mAAmm0ySlFboz21COd+sjQCpj7/Q+xRlooYxLBxRQqIILDsvcGqGAaGuXfWKBOdGlYrgDpMhIBfoxIAB+yTbBqyYAvv57mDuIz7ByNtkSrWfn9OFp83N3QJJHRyGCIvkRyz+UWhbCXtNSBPP+SQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com; spf=pass smtp.mailfrom=huawei.com; arc=none smtp.client-ip=45.249.212.189 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Received: from mail.maildlp.com (unknown [172.19.163.174]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4bR6B22yxMzPtKl; Tue, 24 Jun 2025 09:02:34 +0800 (CST) Received: from kwepemk100013.china.huawei.com (unknown [7.202.194.61]) by mail.maildlp.com (Postfix) with ESMTPS id 0F72414020C; Tue, 24 Jun 2025 09:06:24 +0800 (CST) Received: from [10.67.120.192] (10.67.120.192) by kwepemk100013.china.huawei.com (7.202.194.61) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.11; Tue, 24 Jun 2025 09:06:23 +0800 Message-ID: <96bc6695-5e9a-4a50-8ea6-c4625806af28@huawei.com> Date: Tue, 24 Jun 2025 09:06:22 +0800 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird CC: , , , , , , , , , , , , , , , Subject: Re: [PATCH v2 net-next 1/3] net: hibmcge: support scenario without PHY. To: Andrew Lunn References: <20250623034129.838246-1-shaojijie@huawei.com> <20250623034129.838246-2-shaojijie@huawei.com> <51a9e27a-8a67-4188-8875-8cd81e34765a@lunn.ch> From: Jijie Shao In-Reply-To: <51a9e27a-8a67-4188-8875-8cd81e34765a@lunn.ch> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: kwepems100002.china.huawei.com (7.221.188.206) To kwepemk100013.china.huawei.com (7.202.194.61) on 2025/6/23 15:32, Andrew Lunn wrote: > On Mon, Jun 23, 2025 at 11:41:27AM +0800, Jijie Shao wrote: >> Currently, the driver uses phylib to operate PHY by default. >> >> On some boards, the PHY device is separated from the MAC device. >> As a result, the hibmcge driver cannot operate the PHY device. >> >> In this patch, the driver determines whether a PHY is available >> based on register configuration. If no PHY is available, >> the driver intercepts phylib operations and operates only MAC device. > > The standard way to handle a MAC without a PHY is to use > fixed_link. It is a fake PHY which follows the usual API, so your MAC > driver does not need to care there is no PHY. > > > Andrew Thank you for the guidance, I will study and use it. Thanks Jijie Shao