From nobody Mon Dec 19 13:10:14 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4NbKnL3Vs7z1GvGq; Mon, 19 Dec 2022 13:10:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4NbKnL33tHz4CS4; Mon, 19 Dec 2022 13:10:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1671455414; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=DO7XCtM1k/7X/xnzGs4NO6cGsbSwhqO3BbcZGmR9myQ=; b=hHf5HuENmUHDhlEY6HBF9/o44gQsn9yt0Z0jzOasxkec4XZwuc6Ggon7eB2nfRu0L8ZTR0 HaIXXd86JPjDKxBgxVynlKQM9oTDbhmRwiMdqEcXnmxEhFB5GIQceYz+ULZo/dN4dyGWBO e7SP+WWftzi1dR37nEnz4fNMEQg+0G4C6hLRboI7Kdzpqy4LxFES6wf562DWM6U6nTxgQ8 zYY26RZhFj7UtjYi4IE9ahjQhVymNM7R1KAntYnGvDe/VdAhDCnHTQ6d+WfW0QQTur9kbD d64tePOsDc5Mucyaf5Kl504rUhxMbntXpQ39mmivl1gSs1/KHzN8/7UanAjXdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1671455414; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=DO7XCtM1k/7X/xnzGs4NO6cGsbSwhqO3BbcZGmR9myQ=; b=HjXRViMSKVehyJv2R79u19UbBohQbpt2PkiJLHaplyxhg+L6cQd66u7dEUAfycn0lq6WeU 6oUEk1YsW/dyoVUtDTBdSO5+m7sajlNMuUp5b0d7Qb0Qwdd/jh4f5B1ScOPo3WnFxrJ65X iIn6Q338qyjJDeV3aV/uYm51zy/Y0ly92Z5MGD4yGVnAsSgX9pQl0nRpG5JSHcLRrNof00 dw3Ib8GOIk19V77xXsP6Nf0GWQd2xJ42ac4AcHn7TwkFdEu1Q2dXiM0RgMLwSRfTHdWopR AOr1gSIYOpMsY0bc5l4Mz2PhkW0etyI3bCqr60Q3nMAVCzQ6kaKjgIhknjUWCA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1671455414; a=rsa-sha256; cv=none; b=lBL2VopK5cL+qjsde7lpkq3L4UZJJUzSrF19W1rkgezvW1nvOSewsG2B2ZnOdR++xXs4E9 3m38lSX0nJhx0MeRet9y8+iYEyRYyKgg9+bWTKbpWounDF1yGXW8rVYp7v8arFjAIM3/Q0 Dy+7dMQaydv4IiMfqoVvb9Krwx6V/GuA7zsnJr5Gb/nXzIWoorWEEOKgHgfMGL84lLiGEI 2AivjC0z7xjHAiYo91ELXvD1erGx14CvLrVhalLVuawFs35RoPbPMXFSNxAL2iQ77glq/w 8IrReIKi7kjrJIbrVTXOUb3WglAYX3sBK5R4E0coILSMceGqBBl4FM1EZKRCwQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4NbKnL28BMzx13; Mon, 19 Dec 2022 13:10:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 2BJDAEh5075673; Mon, 19 Dec 2022 13:10:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2BJDAErn075666; Mon, 19 Dec 2022 13:10:14 GMT (envelope-from git) Date: Mon, 19 Dec 2022 13:10:14 GMT Message-Id: <202212191310.2BJDAErn075666@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Ganbold Tsagaankhuu Subject: git: 6692670f58f9 - main - Enable setting the phy id. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: ganbold X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6692670f58f9069e59bc0c958fdaefb9bea5f726 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by ganbold: URL: https://cgit.FreeBSD.org/src/commit/?id=6692670f58f9069e59bc0c958fdaefb9bea5f726 commit 6692670f58f9069e59bc0c958fdaefb9bea5f726 Author: Søren Schmidt AuthorDate: 2022-12-19 12:56:51 +0000 Commit: Ganbold Tsagaankhuu CommitDate: 2022-12-19 13:08:42 +0000 Enable setting the phy id. It is needed for the RK356X combo phy. --- sys/dev/extres/phy/phy.c | 7 +++++++ sys/dev/extres/phy/phy.h | 1 + 2 files changed, 8 insertions(+) diff --git a/sys/dev/extres/phy/phy.c b/sys/dev/extres/phy/phy.c index 0ed633ffbe41..e95cfdfbd4b3 100644 --- a/sys/dev/extres/phy/phy.c +++ b/sys/dev/extres/phy/phy.c @@ -210,6 +210,13 @@ intptr_t phynode_get_id(struct phynode *phynode) return (phynode->id); } +void +phynode_set_id(struct phynode *phynode, intptr_t id) +{ + + phynode->id = id; +} + #ifdef FDT phandle_t phynode_get_ofw_node(struct phynode *phynode) diff --git a/sys/dev/extres/phy/phy.h b/sys/dev/extres/phy/phy.h index b0e5249e4246..34ba59447257 100644 --- a/sys/dev/extres/phy/phy.h +++ b/sys/dev/extres/phy/phy.h @@ -65,6 +65,7 @@ struct phynode *phynode_register(struct phynode *phynode); void *phynode_get_softc(struct phynode *phynode); device_t phynode_get_device(struct phynode *phynode); intptr_t phynode_get_id(struct phynode *phynode); +void phynode_set_id(struct phynode *phynode, intptr_t id); int phynode_enable(struct phynode *phynode); int phynode_disable(struct phynode *phynode); int phynode_status(struct phynode *phynode, int *status);