From patchwork Tue Feb 20 09:46:00 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mauro Carvalho Chehab X-Patchwork-Id: 20648 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:693c:2685:b0:108:e6aa:91d0 with SMTP id mn5csp292216dyc; Tue, 20 Feb 2024 01:50:45 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCUxtBjQzWnVX+D4iNlEf0m05E5MpVYECLC65+JNBAPCP0gyA85qNu+wF/QviEZQXp4xY5JDFm1tWyvMZGUUY278vQ4Ajw== X-Google-Smtp-Source: AGHT+IHa6mFJLgbHL/8Tm/b9LyGLAaco5FvE7gAbq3URi3RR8MFvZ8QCDam2hgDVtGYfvTRUCiSY X-Received: by 2002:a05:6214:2a48:b0:68f:6dc5:149c with SMTP id jf8-20020a0562142a4800b0068f6dc5149cmr6568944qvb.61.1708422645633; Tue, 20 Feb 2024 01:50:45 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708422645; cv=pass; d=google.com; s=arc-20160816; b=AFUXQjxFNZm30ZwkMEICTT6kV3p92RagiCq+Xke76FvOCBuUZYgiQuUSo42sHbPAKk HOUwblza7iuqfoENI9Rcj75BzjtDJ41kVmjCNQBBB+nZGBuVgk/BYcGSxyHQi5EHzAXY dyZIb1dK5NOAgL4FrMuw33lrtkmH0DiprlnjUiwAGHBgL4Q8hVO3KITNQ3GXXjk51Iba PxHvM8Z8jLH5JVvtcuiTvj+/Ue47o5FPmJst9TrrqmmyNt7PZUI9Hx1i/01B5KB1jlI+ GQK72Sm9YtRYeOXLnmjiHfMZ25TH4xJp4X5+p33qZtVGYVIxSRhdqMRxktJJc4fet1J1 nTEA== 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=cSqKA6/vtlZ47M3oKsB99xlJchzvknuMh9yzVvNcUmo=; fh=/cAvgwME2eOirL4KNPaTeXNgPCcXHVmkdPl/7K8ONqM=; b=BcIl7rPWtF2UNR7s3yHrHLGXDJre4RjpjVSPXYqr2v13PG92kZpeZTNBaY9/XBNW/F c5AXiUF9tPKy5Bdas2LM4+8ZzsBdXKG2WS87Dd6ClnCmOunrZiE3eJWYBZ6liEockqI5 l4nNg5HQ4B0uRBOv6nSqFDaeC64sW+qlFX8597wn5fEZL4xtTLiBZbHu/FlAI1vCCzPp 0RsVRgnAWGShudYmFsB6XpVO+LLIXGkplg+Cuu9LmVsSL0he7fC99SdQ2odNJ9l2gpsk iFZpDTkpG8/taFVwIAx3DCxg6s3+DNBsJGrMbtREbzUJ/rhYKeXB2vbdqhgJQTx+TN1I n6PQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=iINWP9PW; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-72735-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-72735-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id gy10-20020a056214242a00b0068f572929b0si6079069qvb.78.2024.02.20.01.50.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Feb 2024 01:50:45 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-72735-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=iINWP9PW; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-72735-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-72735-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.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 66EE21C21313 for ; Tue, 20 Feb 2024 09:50:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EE92A67C66; Tue, 20 Feb 2024 09:46:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="iINWP9PW" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 5956267A0D; Tue, 20 Feb 2024 09:46:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708422389; cv=none; b=R+w3ZX0y3houMZxFjJ5dkF/uGoRUIZSRLf2SDx+xyhBYBhBxB2v5VeD8AXjuCSRkkEdQjNfyBZq8EmEyjBkzlrFzRYV7vhs2+A2d4HwJrusy/BncpTXVYdIHrIcp0G05qLmCaLIYsTdshhxsolShzCESxduCKjH52azeSZ4wRdw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708422389; c=relaxed/simple; bh=As0fs15zX6e/lVzirTWd9KBu940ZNj9/uvV35M86qz0=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=MjoiS9tZrjgkS0GzmuXYH2ZL9MerxqxvAhYQVnoVw3ASRW65PGdYXWSuiNjpIfPB9nURh0jpRTJzWvfgzktpOvbEpZjzfkaR8wmpKmxheJEl3WLfFYIRwTu1P7ZJHsClfqmj3jDYmeglQ5yvPtzfnwG6ukeRL8PjoBvRxAaZIpw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=iINWP9PW; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 014AEC433F1; Tue, 20 Feb 2024 09:46:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1708422389; bh=As0fs15zX6e/lVzirTWd9KBu940ZNj9/uvV35M86qz0=; h=From:To:Cc:Subject:Date:From; b=iINWP9PWAyR9xHeTa/2TFnmNehIsm4u/jt68pRmpFE80YN9QXk+hd5MPYByCht+wP /wxyKpkGLZUeXbdGPhImBZWbrJakB7KujDkH08H8Z/ahBa3VzYERNxx8KD8vcB/EUC /EMLQqq0OKkiYC0vOGTse71SuSrqTVhtnHhk9Sj/t46rtk+SGyeVMxdYr/5vpB3NGH 8PIfdBz85mdGEafsHQi3oxlAriRnCF7Ny/5mjM4vjn9asuhmwaWWO2A2ixU9zfRQFS 8nPhMnOoORlqm+jMiQdeMY44SpUAxREUuIkJsB7cH7zsQt6EKquix3s5u3KIzvFNj+ F5q/lLnHxCZZw== Received: from mchehab by mail.kernel.org with local (Exim 4.97.1) (envelope-from ) id 1rcMhm-000000031Qp-2QwH; Tue, 20 Feb 2024 10:46:26 +0100 From: Mauro Carvalho Chehab To: Cc: Mauro Carvalho Chehab , linux-kernel@vger.kernel.org, linux-media@vger.kernel.org Subject: [PATCH 0/2] Add some uevent variables on DVB to support persistent names on udev Date: Tue, 20 Feb 2024 10:46:00 +0100 Message-ID: X-Mailer: git-send-email 2.43.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1791410983898515322 X-GMAIL-MSGID: 1791410983898515322 As pointed by https://github.com/systemd/systemd/issues/31406, currently, udev doesn't have pesistent names for the subsystem. Add adapter's name and device's parent device, as those may help adding unique persistent names. While here, also change em28xx-dvb to use a real name instead of the parent dev name. With that, uevent for DVB devnodes will resemble this: /sys/class/dvb/dvb0.demux0/uevent:MAJOR=212 /sys/class/dvb/dvb0.demux0/uevent:MINOR=1 /sys/class/dvb/dvb0.demux0/uevent:DEVNAME=dvb/adapter0/demux0 /sys/class/dvb/dvb0.demux0/uevent:DVB_ADAPTER_NAME=PCTV nanoStick T2 290e /sys/class/dvb/dvb0.demux0/uevent:DVB_ADAPTER_PDEV=2-1:1.0 /sys/class/dvb/dvb0.demux0/uevent:DVB_ADAPTER_NUM=0 /sys/class/dvb/dvb0.demux0/uevent:DVB_DEVICE_TYPE=demux /sys/class/dvb/dvb0.demux0/uevent:DVB_DEVICE_NUM=0 Tested with a PCTV nanoStick T2 290e device. Mauro Carvalho Chehab (2): media: dvbdev: export adapter's name and bus ID to DVB uevent variables em28xx-dvb: fix DVB adapter device name drivers/media/dvb-core/dvbdev.c | 2 ++ drivers/media/usb/em28xx/em28xx-dvb.c | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-)