From patchwork Thu Nov 23 09:40:25 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiner Kallweit X-Patchwork-Id: 13465992 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="QT5Zx0xj" Received: from mail-ej1-x62f.google.com (mail-ej1-x62f.google.com [IPv6:2a00:1450:4864:20::62f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B02F8CB; Thu, 23 Nov 2023 01:40:50 -0800 (PST) Received: by mail-ej1-x62f.google.com with SMTP id a640c23a62f3a-9fd0059a967so341013466b.1; Thu, 23 Nov 2023 01:40:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700732449; x=1701337249; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=qvHXeOl9LDkuvADN7QZ3xhK0GHlO5gQYDZefl63t5jE=; b=QT5Zx0xjlKBFQFSdf6/WfoaeV6yfuDcOxuxxLtgtKRgeZdcQ4PwJSqaLLqrDA2+rKz a+lj/QakBerplMn6+BRIDup85YF2iI4UttD9LcdoqJqF3bxILWfYm/wyLVVpAwhphlR0 w4PIps911JCHGt7KyiBhTeaqFhhzfzsfvfrOvAcZck25dST0J4QB/cRMdyZ3OOUgejon u/UOG8Sy95JFEi1KlCsiRr3xgT1CSMaySh6UcxNoxNL/ZpJ1Gk8AOx4kVbdXYaRocnWk Mfh+cuVBBY7uPA1sDKlhRiJr9GnRLKvw3UoeHFrivnH26y0jfwLXSQws190llOZRfFaA mWhA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700732449; x=1701337249; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=qvHXeOl9LDkuvADN7QZ3xhK0GHlO5gQYDZefl63t5jE=; b=kS3hBBr/muHbaEkWLx+jY1bboRl3rPaqz2WGiTjzaDyzEbcaMAJn2e6FjRWZ+rpgy+ 4COvBEp6yChBf7wDHN0uug4QKBMMCG7TJ2MuF57Vf+7YLmVmI2LaOIMnz4bkgAszX+cY 3Z0DMxqkwX5v0Koea6B8MhyZH6zhBNsDiweKEUohquXH4ZoBfJYRyY5h1vIeY2A7m5HG cZqu/Tk0f52cuY2lkEngLUkaQh6fwe6wdByX0Nq/0GHV11GAPujn4aZ1ndeTbDH2j5Wz G/s4oCXcLQFHgbq+W1MZWSlj57vw42+I6LupLYutAQGF5D8z9LA8l8RNJOHAFEzS0xnX Tl7Q== X-Gm-Message-State: AOJu0YwExOnWK/OTXOP1+DA/ZPS8aTBkIkdVCnV9F+eKVTCvh83Zth2q HnjNk013tkERQBG2ixgxi20= X-Google-Smtp-Source: AGHT+IE+Nr8u8YtY1qrwt9z7+2FQgdGwO8TfYUwKqW78GiAu5HXb3TRPaqDDQPPM8YSMZBIRnZFVyQ== X-Received: by 2002:a17:906:3299:b0:9ae:659f:4d2f with SMTP id 25-20020a170906329900b009ae659f4d2fmr2095489ejw.26.1700732449059; Thu, 23 Nov 2023 01:40:49 -0800 (PST) Received: from zotac.lan. (dynamic-2a01-0c23-c0f2-3200-2223-08ff-fe18-0310.c23.pool.telefonica.de. [2a01:c23:c0f2:3200:2223:8ff:fe18:310]) by smtp.gmail.com with ESMTPSA id s9-20020a1709066c8900b009e5ce1acb01sm546199ejr.103.2023.11.23.01.40.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 01:40:48 -0800 (PST) From: Heiner Kallweit To: Wolfram Sang , Helge Deller Cc: linux-i2c@vger.kernel.org, Heiner Kallweit , linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Thomas Zimmermann Subject: [PATCH v5 05/20] drivers/video/fbdev: remove I2C_CLASS_DDC support Date: Thu, 23 Nov 2023 10:40:25 +0100 Message-ID: <20231123094040.592-6-hkallweit1@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231123094040.592-1-hkallweit1@gmail.com> References: <20231123094040.592-1-hkallweit1@gmail.com> Precedence: bulk X-Mailing-List: linux-fbdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 After removal of the legacy EEPROM driver and I2C_CLASS_DDC support in olpc_dcon there's no i2c client driver left supporting I2C_CLASS_DDC. Class-based device auto-detection is a legacy mechanism and shouldn't be used in new code. So we can remove this class completely now. Preferably this series should be applied via the i2c tree. Acked-by: Helge Deller Acked-by: Thomas Zimmermann Signed-off-by: Heiner Kallweit --- v3: - fix compile error --- drivers/video/fbdev/i740fb.c | 1 - drivers/video/fbdev/matrox/i2c-matroxfb.c | 15 +++++---------- drivers/video/fbdev/s3fb.c | 1 - drivers/video/fbdev/tdfxfb.c | 1 - drivers/video/fbdev/tridentfb.c | 1 - 5 files changed, 5 insertions(+), 14 deletions(-) diff --git a/drivers/video/fbdev/i740fb.c b/drivers/video/fbdev/i740fb.c index 1897e65ab..9b74dae71 100644 --- a/drivers/video/fbdev/i740fb.c +++ b/drivers/video/fbdev/i740fb.c @@ -163,7 +163,6 @@ static int i740fb_setup_ddc_bus(struct fb_info *info) strscpy(par->ddc_adapter.name, info->fix.id, sizeof(par->ddc_adapter.name)); par->ddc_adapter.owner = THIS_MODULE; - par->ddc_adapter.class = I2C_CLASS_DDC; par->ddc_adapter.algo_data = &par->ddc_algo; par->ddc_adapter.dev.parent = info->device; par->ddc_algo.setsda = i740fb_ddc_setsda; diff --git a/drivers/video/fbdev/matrox/i2c-matroxfb.c b/drivers/video/fbdev/matrox/i2c-matroxfb.c index e2e4705e3..bb048e14b 100644 --- a/drivers/video/fbdev/matrox/i2c-matroxfb.c +++ b/drivers/video/fbdev/matrox/i2c-matroxfb.c @@ -100,8 +100,7 @@ static const struct i2c_algo_bit_data matrox_i2c_algo_template = }; static int i2c_bus_reg(struct i2c_bit_adapter* b, struct matrox_fb_info* minfo, - unsigned int data, unsigned int clock, const char *name, - int class) + unsigned int data, unsigned int clock, const char *name) { int err; @@ -112,7 +111,6 @@ static int i2c_bus_reg(struct i2c_bit_adapter* b, struct matrox_fb_info* minfo, snprintf(b->adapter.name, sizeof(b->adapter.name), name, minfo->fbcon.node); i2c_set_adapdata(&b->adapter, b); - b->adapter.class = class; b->adapter.algo_data = &b->bac; b->adapter.dev.parent = &minfo->pcidev->dev; b->bac = matrox_i2c_algo_template; @@ -160,27 +158,24 @@ static void* i2c_matroxfb_probe(struct matrox_fb_info* minfo) { case MGA_2164: err = i2c_bus_reg(&m2info->ddc1, minfo, DDC1B_DATA, DDC1B_CLK, - "DDC:fb%u #0", I2C_CLASS_DDC); + "DDC:fb%u #0"); break; default: err = i2c_bus_reg(&m2info->ddc1, minfo, DDC1_DATA, DDC1_CLK, - "DDC:fb%u #0", I2C_CLASS_DDC); + "DDC:fb%u #0"); break; } if (err) goto fail_ddc1; if (minfo->devflags.dualhead) { - err = i2c_bus_reg(&m2info->ddc2, minfo, - DDC2_DATA, DDC2_CLK, - "DDC:fb%u #1", I2C_CLASS_DDC); + err = i2c_bus_reg(&m2info->ddc2, minfo, DDC2_DATA, DDC2_CLK, "DDC:fb%u #1"); if (err == -ENODEV) { printk(KERN_INFO "i2c-matroxfb: VGA->TV plug detected, DDC unavailable.\n"); } else if (err) printk(KERN_INFO "i2c-matroxfb: Could not register secondary output i2c bus. Continuing anyway.\n"); /* Register maven bus even on G450/G550 */ - err = i2c_bus_reg(&m2info->maven, minfo, - MAT_DATA, MAT_CLK, "MAVEN:fb%u", 0); + err = i2c_bus_reg(&m2info->maven, minfo, MAT_DATA, MAT_CLK, "MAVEN:fb%u"); if (err) printk(KERN_INFO "i2c-matroxfb: Could not register Maven i2c bus. Continuing anyway.\n"); else { diff --git a/drivers/video/fbdev/s3fb.c b/drivers/video/fbdev/s3fb.c index 589b349cb..07722a5ea 100644 --- a/drivers/video/fbdev/s3fb.c +++ b/drivers/video/fbdev/s3fb.c @@ -252,7 +252,6 @@ static int s3fb_setup_ddc_bus(struct fb_info *info) strscpy(par->ddc_adapter.name, info->fix.id, sizeof(par->ddc_adapter.name)); par->ddc_adapter.owner = THIS_MODULE; - par->ddc_adapter.class = I2C_CLASS_DDC; par->ddc_adapter.algo_data = &par->ddc_algo; par->ddc_adapter.dev.parent = info->device; par->ddc_algo.setsda = s3fb_ddc_setsda; diff --git a/drivers/video/fbdev/tdfxfb.c b/drivers/video/fbdev/tdfxfb.c index 22aa95313..51ebe7835 100644 --- a/drivers/video/fbdev/tdfxfb.c +++ b/drivers/video/fbdev/tdfxfb.c @@ -1267,7 +1267,6 @@ static int tdfxfb_setup_ddc_bus(struct tdfxfb_i2c_chan *chan, const char *name, strscpy(chan->adapter.name, name, sizeof(chan->adapter.name)); chan->adapter.owner = THIS_MODULE; - chan->adapter.class = I2C_CLASS_DDC; chan->adapter.algo_data = &chan->algo; chan->adapter.dev.parent = dev; chan->algo.setsda = tdfxfb_ddc_setsda; diff --git a/drivers/video/fbdev/tridentfb.c b/drivers/video/fbdev/tridentfb.c index 816d40b6f..516cf2a18 100644 --- a/drivers/video/fbdev/tridentfb.c +++ b/drivers/video/fbdev/tridentfb.c @@ -274,7 +274,6 @@ static int tridentfb_setup_ddc_bus(struct fb_info *info) strscpy(par->ddc_adapter.name, info->fix.id, sizeof(par->ddc_adapter.name)); par->ddc_adapter.owner = THIS_MODULE; - par->ddc_adapter.class = I2C_CLASS_DDC; par->ddc_adapter.algo_data = &par->ddc_algo; par->ddc_adapter.dev.parent = info->device; if (is_oldclock(par->chip_id)) { /* not sure if this check is OK */ From patchwork Thu Nov 23 09:40:26 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiner Kallweit X-Patchwork-Id: 13465991 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="L+nUW6jo" Received: from mail-ed1-x533.google.com (mail-ed1-x533.google.com [IPv6:2a00:1450:4864:20::533]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5EB6F1A4; Thu, 23 Nov 2023 01:40:51 -0800 (PST) Received: by mail-ed1-x533.google.com with SMTP id 4fb4d7f45d1cf-548d60a4d60so849427a12.2; Thu, 23 Nov 2023 01:40:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700732450; x=1701337250; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=T4xwkZlQCS57rh5cLLkPqLJtM9ewQjK5YT1ZnNRRYzc=; b=L+nUW6joC/xY5dKblIyi4QUSjOUDmSummlD50kmpmvnKsbLdts8gvFnkTVBCnuFb/6 jvDUa+mU2fT5xI13X5qdHyN5GQOVeAdMmfUcO3fqx//OrrwIhVCdvEcvqArpJUswQJDR 0gOntavuQvMPOYMnSzGJHxph/9PRf3M5thVawQ3/a16iW76ZG39QWiWhsoMF3q8b+/9L wcL/iCpZEZFsnofPAv+FSwKyKy6SzD4Ij0UFboPXlnuizKZbpAYr9yE6V1mP3qjt+yPj mRZZ2gHW+B+y5QIRW5aHleiJ0D2AQN2kdp5Zzz99w6ojS9u4lYpE99LIhDT6WInoSazG PVFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700732450; x=1701337250; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=T4xwkZlQCS57rh5cLLkPqLJtM9ewQjK5YT1ZnNRRYzc=; b=qbHUg3pHITKq/O33T+GjhyKJQt34XgwKqR/DXK3BNGZc1B3My1jalA2R1IC2Uf6p6f HQW9G8Jqn5qVeCAJnBnxOI1AWF2+SEiucu7Wtux3z+7Q9eVHfkoi+e6XbDSr0id4GlQ3 ykCfCv0Gxbd8adRfwFdjBQ/qvbSrFQfgzQ/Sy1hdt5/CdPeOwwlZ2KXPBdL7mdLkD16k +meK4Kdjap2F6VVRFb+YA/neyGVBKoMl2cW/QbY/Ck2wqx48Mve1KIhRZvUoTUSFSx1i kOo2/UCt8cAzkuVGuSSdBUz1khzTPouPK7Mi4Hxtylcy70O6n/0PEwoN7AuvVNa3+RD4 6onQ== X-Gm-Message-State: AOJu0YyQ0MHsCh4qypVKADA8FGC9xpJTEQANL+6OqOdZidZ9b1Nza+Cj nKRmMsAHWj3rME+oWlGoqCo= X-Google-Smtp-Source: AGHT+IHb38lKBzahmB3scsQJ4G9h8mrxfVKAwJLraoLG53oT4I/ucTZBBGxcgUItZfDjTqSw8rrB4w== X-Received: by 2002:a17:906:7197:b0:9e3:5c27:8862 with SMTP id h23-20020a170906719700b009e35c278862mr3223427ejk.27.1700732449746; Thu, 23 Nov 2023 01:40:49 -0800 (PST) Received: from zotac.lan. (dynamic-2a01-0c23-c0f2-3200-2223-08ff-fe18-0310.c23.pool.telefonica.de. [2a01:c23:c0f2:3200:2223:8ff:fe18:310]) by smtp.gmail.com with ESMTPSA id s9-20020a1709066c8900b009e5ce1acb01sm546199ejr.103.2023.11.23.01.40.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 01:40:49 -0800 (PST) From: Heiner Kallweit To: Wolfram Sang , Daniel Vetter Cc: linux-i2c@vger.kernel.org, Heiner Kallweit , Helge Deller , linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Thomas Zimmermann Subject: [PATCH v5 06/20] drivers/video/fbdev/core/fb_ddc.c: remove I2C_CLASS_DDC support Date: Thu, 23 Nov 2023 10:40:26 +0100 Message-ID: <20231123094040.592-7-hkallweit1@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231123094040.592-1-hkallweit1@gmail.com> References: <20231123094040.592-1-hkallweit1@gmail.com> Precedence: bulk X-Mailing-List: linux-fbdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 After removal of the legacy EEPROM driver and I2C_CLASS_DDC support in olpc_dcon there's no i2c client driver left supporting I2C_CLASS_DDC. Class-based device auto-detection is a legacy mechanism and shouldn't be used in new code. So we can remove this class completely now. Preferably this series should be applied via the i2c tree. Acked-by: Helge Deller Acked-by: Thomas Zimmermann Signed-off-by: Heiner Kallweit --- drivers/video/fbdev/core/fb_ddc.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/video/fbdev/core/fb_ddc.c b/drivers/video/fbdev/core/fb_ddc.c index 8bf5f2f54..e25143219 100644 --- a/drivers/video/fbdev/core/fb_ddc.c +++ b/drivers/video/fbdev/core/fb_ddc.c @@ -116,7 +116,6 @@ unsigned char *fb_ddc_read(struct i2c_adapter *adapter) algo_data->setsda(algo_data->data, 1); algo_data->setscl(algo_data->data, 1); - adapter->class |= I2C_CLASS_DDC; return edid; } From patchwork Thu Nov 23 09:40:29 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiner Kallweit X-Patchwork-Id: 13465993 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="OVwoZwgl" Received: from mail-ej1-x62c.google.com (mail-ej1-x62c.google.com [IPv6:2a00:1450:4864:20::62c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0CF62D53; Thu, 23 Nov 2023 01:40:54 -0800 (PST) Received: by mail-ej1-x62c.google.com with SMTP id a640c23a62f3a-a03a9009572so79629666b.3; Thu, 23 Nov 2023 01:40:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700732452; x=1701337252; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=YSszigu6T9QU12VdWtO4WfxwIpZgiTTUkpWgQw1TPZ8=; b=OVwoZwglOywb8LudcE8l9Taw5B91vDI/Xx3E86YoRfHBu5WwPbvMDHC0uuqJN6qNgf KbUr2NIaSRqqaPC3j6razei9CupS3d/Qr6jwLGBusdcbtkru6uu7BK7uncvYZiYBYiW0 9+GmK0elaZ8SDLsBEhz9+4sJJYNbDJwTZnUNk1DGEBHYd3/OIw0yq+O4bYrIqv6+/6zF RII2JWLwNoyAy/jeRUjJz7H3m5eZmv2wlbA9zK1mgc8XAVPG+OZaH1uZ4WetsIYKMCe/ /7U408NBQhoO0cwj+OYEuat+S1urdbqbPbJLSREAZUc4y7XQB3wZTgeLZ7j3MZDmTbPy QccQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700732452; x=1701337252; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=YSszigu6T9QU12VdWtO4WfxwIpZgiTTUkpWgQw1TPZ8=; b=H0Aa2ixMRRp2uYVJ0UA/yGa2dNxKS90UT9ua1SjzcuTDPIk4xng2y3tmWN2PGx8qIg aEGBK7qPd9wbF30cndQDOWE4kKtWW00OMuSqFNmXbAjkuTWBy/K6CR4f0axVxsgaHDhm eBnyP4b6BSpFU6SyqgmfRDvicaWUo9GotFqCfH6ihf0nsuPdKbmOkZhBQ+Yab5Pp7ste NztcdxLSqSgJIft9/iQJB5OQ6h4AJGd/o+udLlgm+T8hp9DB9ZagTXoP7yi2Ncnq9rvg desaqUm0ocx2nLqcjWsBshlcggW7WHr5SbcXu0FhYSc6Is7B/DgI8FwSAQ3KdbNyY6MJ wZ9Q== X-Gm-Message-State: AOJu0YwgEFfmNO8FiWOoBpmW45X7wd51zHBxfTuI2YOe2X2R8g4Aj/DE 05XBDuZcWZE0xByfzJTLu8k= X-Google-Smtp-Source: AGHT+IEFgOtT3lal4jlY4JZycrJ9xFNnfqhiTE1G5PpC/tUinLgJ+nSg0oiXXan59RSRf9SexqP77g== X-Received: by 2002:a17:906:209:b0:a02:9c3d:6de7 with SMTP id 9-20020a170906020900b00a029c3d6de7mr3506760ejd.13.1700732452416; Thu, 23 Nov 2023 01:40:52 -0800 (PST) Received: from zotac.lan. (dynamic-2a01-0c23-c0f2-3200-2223-08ff-fe18-0310.c23.pool.telefonica.de. [2a01:c23:c0f2:3200:2223:8ff:fe18:310]) by smtp.gmail.com with ESMTPSA id s9-20020a1709066c8900b009e5ce1acb01sm546199ejr.103.2023.11.23.01.40.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 01:40:51 -0800 (PST) From: Heiner Kallweit To: Wolfram Sang , Florian Tobias Schandinat Cc: linux-i2c@vger.kernel.org, Heiner Kallweit , Helge Deller , linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Thomas Zimmermann Subject: [PATCH v5 09/20] drivers/video/fbdev/via/via_i2c.c: remove I2C_CLASS_DDC support Date: Thu, 23 Nov 2023 10:40:29 +0100 Message-ID: <20231123094040.592-10-hkallweit1@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231123094040.592-1-hkallweit1@gmail.com> References: <20231123094040.592-1-hkallweit1@gmail.com> Precedence: bulk X-Mailing-List: linux-fbdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 After removal of the legacy EEPROM driver and I2C_CLASS_DDC support in olpc_dcon there's no i2c client driver left supporting I2C_CLASS_DDC. Class-based device auto-detection is a legacy mechanism and shouldn't be used in new code. So we can remove this class completely now. Preferably this series should be applied via the i2c tree. Acked-by: Helge Deller Acked-by: Thomas Zimmermann Signed-off-by: Heiner Kallweit --- drivers/video/fbdev/via/via_i2c.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/video/fbdev/via/via_i2c.c b/drivers/video/fbdev/via/via_i2c.c index c35e530e0..582502810 100644 --- a/drivers/video/fbdev/via/via_i2c.c +++ b/drivers/video/fbdev/via/via_i2c.c @@ -201,7 +201,6 @@ static int create_i2c_bus(struct i2c_adapter *adapter, sprintf(adapter->name, "viafb i2c io_port idx 0x%02x", adap_cfg->ioport_index); adapter->owner = THIS_MODULE; - adapter->class = I2C_CLASS_DDC; adapter->algo_data = algo; if (pdev) adapter->dev.parent = &pdev->dev; From patchwork Thu Nov 23 09:40:30 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiner Kallweit X-Patchwork-Id: 13465994 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="D0aDHZ6G" Received: from mail-ej1-x62d.google.com (mail-ej1-x62d.google.com [IPv6:2a00:1450:4864:20::62d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 26FC01A4; Thu, 23 Nov 2023 01:40:54 -0800 (PST) Received: by mail-ej1-x62d.google.com with SMTP id a640c23a62f3a-a013d22effcso79270466b.2; Thu, 23 Nov 2023 01:40:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700732453; x=1701337253; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=1X2LDaMbB0c5HZoTNyhIjHAhgnohEDN3uV01ROjEnUc=; b=D0aDHZ6GvGqBNZyanabWGNj9zDgGbkkjWPxW3QCsS0g4G3eIuqN8hsj91YkgbcDm90 Dr2YRdN2djdgcsUPjEDHqR/nm9CrKcPXi74tqT3B9L/0qRipn0VM43J/faMcAiZZFLNv el31maAxsj5ba7rJNsvFgdoyuErKiG5G9aL4gM5/FB4bL+IMd6l7f33gqEm8ZHHFJd3d 8DOYph1l9DwAy8+2nSMQRikv4KByTCHuMVcuPApbb+1h8mOJfLs2fds2Dxq2QnraNEWy r+i0t/kyzp6A97tju3a35qv53I4KTO+YTzf3780IES1uTvIxJY1RBAREvO3IpowxMaD2 ci5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700732453; x=1701337253; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=1X2LDaMbB0c5HZoTNyhIjHAhgnohEDN3uV01ROjEnUc=; b=j7xhLO8o4Dipjsf8zjT+isfcUm27Wohyc1Nhv68Yw/WHG348dyn1smBrLeEbf1jrKh m33Uf2hz32t24vQDgWrkww7vv3fIKrnr9nEIZKMaccVpFloefUrPXnTrmJykhInJEFrv 6spEFAyiPjmFjz08o5DHjCa+Wry04S7b1nlyQKTn1PBD5yevLduTN2bn6dkr4Txmm2GV 1VHFwKshXf6Ss8T4nvkMH23RHI9ky967sXH5ziOV/RCsa+MqIGjqfhglgGXAiwISc9Jq psXORKA8wePMbmHrKUVXoVIrxzczm2mSuw3fem42NsiMoteTTT9QrS5ZT6hS6gGCPaa/ yeug== X-Gm-Message-State: AOJu0YytPhZXXuJU3JpIftQmqssyO3wKaFdivm6QJu8QvYx5VrNPunCt e2fRdMD6YcdFbH74gJoCdaekw2Zlwnw= X-Google-Smtp-Source: AGHT+IG2ldSIvJkPOWRUMwqptBELwha4P3UEDAWFeFhYxPAf0Hq1Cr63BHUft7JxbUZhAWi2pEm5Tg== X-Received: by 2002:a17:907:9382:b0:a00:9550:b08b with SMTP id cm2-20020a170907938200b00a009550b08bmr3262185ejc.24.1700732453321; Thu, 23 Nov 2023 01:40:53 -0800 (PST) Received: from zotac.lan. (dynamic-2a01-0c23-c0f2-3200-2223-08ff-fe18-0310.c23.pool.telefonica.de. [2a01:c23:c0f2:3200:2223:8ff:fe18:310]) by smtp.gmail.com with ESMTPSA id s9-20020a1709066c8900b009e5ce1acb01sm546199ejr.103.2023.11.23.01.40.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 01:40:52 -0800 (PST) From: Heiner Kallweit To: Wolfram Sang , Russell King Cc: linux-i2c@vger.kernel.org, Heiner Kallweit , Helge Deller , linux-arm-kernel@lists.infradead.org, linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Thomas Zimmermann Subject: [PATCH v5 10/20] drivers/video/fbdev/cyber2000fb.c: remove I2C_CLASS_DDC support Date: Thu, 23 Nov 2023 10:40:30 +0100 Message-ID: <20231123094040.592-11-hkallweit1@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231123094040.592-1-hkallweit1@gmail.com> References: <20231123094040.592-1-hkallweit1@gmail.com> Precedence: bulk X-Mailing-List: linux-fbdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 After removal of the legacy EEPROM driver and I2C_CLASS_DDC support in olpc_dcon there's no i2c client driver left supporting I2C_CLASS_DDC. Class-based device auto-detection is a legacy mechanism and shouldn't be used in new code. So we can remove this class completely now. Preferably this series should be applied via the i2c tree. Acked-by: Helge Deller Acked-by: Thomas Zimmermann Signed-off-by: Heiner Kallweit --- drivers/video/fbdev/cyber2000fb.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/video/fbdev/cyber2000fb.c b/drivers/video/fbdev/cyber2000fb.c index 52105dc1a..79775deda 100644 --- a/drivers/video/fbdev/cyber2000fb.c +++ b/drivers/video/fbdev/cyber2000fb.c @@ -1234,7 +1234,6 @@ static int cyber2000fb_setup_ddc_bus(struct cfb_info *cfb) strscpy(cfb->ddc_adapter.name, cfb->fb.fix.id, sizeof(cfb->ddc_adapter.name)); cfb->ddc_adapter.owner = THIS_MODULE; - cfb->ddc_adapter.class = I2C_CLASS_DDC; cfb->ddc_adapter.algo_data = &cfb->ddc_algo; cfb->ddc_adapter.dev.parent = cfb->fb.device; cfb->ddc_algo.setsda = cyber2000fb_ddc_setsda; From patchwork Thu Nov 23 09:40:33 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiner Kallweit X-Patchwork-Id: 13465995 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="fjWwVPsU" Received: from mail-ej1-x62d.google.com (mail-ej1-x62d.google.com [IPv6:2a00:1450:4864:20::62d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4733FD68; Thu, 23 Nov 2023 01:40:57 -0800 (PST) Received: by mail-ej1-x62d.google.com with SMTP id a640c23a62f3a-a02d91ab199so82436066b.0; Thu, 23 Nov 2023 01:40:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700732456; x=1701337256; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=4GQVLU0yIdzvkWpe6EOtR/8b+D+v0ZubEgK+LbytqFk=; b=fjWwVPsUARNs/VHoDvw+mL4gcuTLMp87TVPPHIXI4vRAwPTQf1iHkbSebo6UJRon04 tPCZjQBz4+0S+YCvq4bvmPjqshFlAE2+okqWk0w9H3YaY/9BhDOSZ5cgk8ngIQ8kdYUd ephbv23hFWXKs9BaAw+RSy+6BXnRNE1IJdafCfKBpv+4mtNSpJo4NexAhH0uOz5oCl3S KSEWFoGsHn3sLePq+be9kkERR7OOJeYZSnjY212XtJVG7YU1ExkdP1a8DvTxO6lZ2Fyo 1rSxOd+jLAvQmkFMyEZloLl0ckLnQmySRIdEl88n+mLX0oV83YntN7i1/RENesFf2Imc v2bQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700732456; x=1701337256; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=4GQVLU0yIdzvkWpe6EOtR/8b+D+v0ZubEgK+LbytqFk=; b=hgu9yuraYqQohUH32EqSrDp6cdSjFuQqC90twdC95t/aTMvzbgJyWfgQSjSwSOEgJO bRtK3uT9tWLVAgzRRySNUcRThNqd9rDHCDEvjH4VsUYw3YkJt+hFmK/bUC7lpY5O1zf4 PfXHfkKV1LQofZPH+jEYVqfdGI8pOA6i+hb5HWoibcyfjMa6TC6Pb1dqPQmsZ6zoDKbE a9rsRLdNFveaevxMkIPLiF50YgZguIOG99P6C21doUoX+nl+7RAskPEw3sxAKgi62Vwn DA/Jlgq1P6vzD85jwivfH4/UtWnXgEVHdxKl787dG/KuY5LhsvQbaFbzrBIRzYvDMefy ed2Q== X-Gm-Message-State: AOJu0Yx2yGuFGK3WW/Fvz4LA20QkH5eILXlC25RT+ykWxJ1Yw3gud3jK yFLmetk+Hbc7pMKixt8Dnhc= X-Google-Smtp-Source: AGHT+IFW7oGp/sxqiNU9T6YyLWfXmVFxlR+ROFim07r/08bufC+IIaX6Uvxyofr/jhfjkQUrN3Ji5Q== X-Received: by 2002:a17:906:1855:b0:a00:8706:c82b with SMTP id w21-20020a170906185500b00a008706c82bmr3269223eje.47.1700732455722; Thu, 23 Nov 2023 01:40:55 -0800 (PST) Received: from zotac.lan. (dynamic-2a01-0c23-c0f2-3200-2223-08ff-fe18-0310.c23.pool.telefonica.de. [2a01:c23:c0f2:3200:2223:8ff:fe18:310]) by smtp.gmail.com with ESMTPSA id s9-20020a1709066c8900b009e5ce1acb01sm546199ejr.103.2023.11.23.01.40.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 01:40:55 -0800 (PST) From: Heiner Kallweit To: Wolfram Sang , Maik Broemme Cc: linux-i2c@vger.kernel.org, Heiner Kallweit , Helge Deller , linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Thomas Zimmermann Subject: [PATCH v5 13/20] drivers/video/fbdev/intelfb/intelfb_i2c.c: remove I2C_CLASS_DDC support Date: Thu, 23 Nov 2023 10:40:33 +0100 Message-ID: <20231123094040.592-14-hkallweit1@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231123094040.592-1-hkallweit1@gmail.com> References: <20231123094040.592-1-hkallweit1@gmail.com> Precedence: bulk X-Mailing-List: linux-fbdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 After removal of the legacy EEPROM driver and I2C_CLASS_DDC support in olpc_dcon there's no i2c client driver left supporting I2C_CLASS_DDC. Class-based device auto-detection is a legacy mechanism and shouldn't be used in new code. So we can remove this class completely now. Preferably this series should be applied via the i2c tree. Acked-by: Helge Deller Acked-by: Thomas Zimmermann Signed-off-by: Heiner Kallweit --- drivers/video/fbdev/intelfb/intelfb_i2c.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/drivers/video/fbdev/intelfb/intelfb_i2c.c b/drivers/video/fbdev/intelfb/intelfb_i2c.c index 3300bd31d..f24c7cb4c 100644 --- a/drivers/video/fbdev/intelfb/intelfb_i2c.c +++ b/drivers/video/fbdev/intelfb/intelfb_i2c.c @@ -99,8 +99,7 @@ static int intelfb_gpio_getsda(void *data) static int intelfb_setup_i2c_bus(struct intelfb_info *dinfo, struct intelfb_i2c_chan *chan, - const u32 reg, const char *name, - int class) + const u32 reg, const char *name) { int rc; @@ -108,7 +107,6 @@ static int intelfb_setup_i2c_bus(struct intelfb_info *dinfo, chan->reg = reg; snprintf(chan->adapter.name, sizeof(chan->adapter.name), "intelfb %s", name); - chan->adapter.class = class; chan->adapter.owner = THIS_MODULE; chan->adapter.algo_data = &chan->algo; chan->adapter.dev.parent = &chan->dinfo->pdev->dev; @@ -144,8 +142,7 @@ void intelfb_create_i2c_busses(struct intelfb_info *dinfo) dinfo->output[i].type = INTELFB_OUTPUT_ANALOG; /* setup the DDC bus for analog output */ - intelfb_setup_i2c_bus(dinfo, &dinfo->output[i].ddc_bus, GPIOA, - "CRTDDC_A", I2C_CLASS_DDC); + intelfb_setup_i2c_bus(dinfo, &dinfo->output[i].ddc_bus, GPIOA, "CRTDDC_A"); i++; /* need to add the output busses for each device @@ -159,10 +156,8 @@ void intelfb_create_i2c_busses(struct intelfb_info *dinfo) case INTEL_855GM: case INTEL_865G: dinfo->output[i].type = INTELFB_OUTPUT_DVO; - intelfb_setup_i2c_bus(dinfo, &dinfo->output[i].ddc_bus, - GPIOD, "DVODDC_D", I2C_CLASS_DDC); - intelfb_setup_i2c_bus(dinfo, &dinfo->output[i].i2c_bus, - GPIOE, "DVOI2C_E", 0); + intelfb_setup_i2c_bus(dinfo, &dinfo->output[i].ddc_bus, GPIOD, "DVODDC_D"); + intelfb_setup_i2c_bus(dinfo, &dinfo->output[i].i2c_bus, GPIOE, "DVOI2C_E"); i++; break; case INTEL_915G: @@ -176,7 +171,7 @@ void intelfb_create_i2c_busses(struct intelfb_info *dinfo) /* SDVO ports have a single control bus - 2 devices */ dinfo->output[i].type = INTELFB_OUTPUT_SDVO; intelfb_setup_i2c_bus(dinfo, &dinfo->output[i].i2c_bus, - GPIOE, "SDVOCTRL_E", 0); + GPIOE, "SDVOCTRL_E"); /* TODO: initialize the SDVO */ /* I830SDVOInit(pScrn, i, DVOB); */ i++;