From patchwork Tue Apr 21 12:49:22 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Micha=C5=82_Winiarski?= X-Patchwork-Id: 11503123 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5AB6B912 for ; Wed, 22 Apr 2020 06:55:51 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 398D5206D9 for ; Wed, 22 Apr 2020 06:55:51 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=hardline-pl.20150623.gappssmtp.com header.i=@hardline-pl.20150623.gappssmtp.com header.b="nQCr8/26" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 398D5206D9 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=hardline.pl Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id D22AE6E9BE; Wed, 22 Apr 2020 06:54:58 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lj1-x244.google.com (mail-lj1-x244.google.com [IPv6:2a00:1450:4864:20::244]) by gabe.freedesktop.org (Postfix) with ESMTPS id F1E816E3EF for ; Tue, 21 Apr 2020 12:50:34 +0000 (UTC) Received: by mail-lj1-x244.google.com with SMTP id j3so13790490ljg.8 for ; Tue, 21 Apr 2020 05:50:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hardline-pl.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=31DLqDGppfY8uxFAvP53qi9Sl1vs7JVUgc/ygd71uoc=; b=nQCr8/26WzE/vq5IepXYp5cSS9Ff8RHaUHv05pE9r8zoaryoqdzHpeWzxtqQY0WwkH 5wFUG6QSlqaslIAhW3iwRcOCYQ/4zYuMc/WeSP5McqhLNX1MKrfOxBRwCTzObftpuJoZ zP8NFpIiQf13WmEDlLgYS3yvsiptxKdCeYqByYBOfi29U3JdInX/pkHv8cqK+US+rx9U BZpbd6SEZZHDvwtlkFJxmjasPfMgt3bUlK0iiPxYGdjX5rzFaNQDzVscHl0UQTIwbLr+ i6kuvC1QJWfu7t3hQDnMiILdfg2BQLlzK7A6HbRO70wZEVS+e0d6LR4mbkO3k5jyTUrH Pv4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=31DLqDGppfY8uxFAvP53qi9Sl1vs7JVUgc/ygd71uoc=; b=OKXmBEgKeeuM0nnhPzBAKKa1TDgvtSpNTNSqEVezi0J3JCysvJZDGehptzLWKARYtl iAr+Rt0iOsjhxL61JzxQASSyQEthua9S/TuB9OHUcFqkPniow6l1cNs5ADsX8HdY5dwJ cNxlY7QECzU15J04GK/pOIKIE9L+0nbYXI0yS8cU7C5EU1i7KzZLFENAaSmuVYc7Ppxd igejhMYo+I+mmGSd8ZupHCyK8Fdz4zibh3P8TjxTCHnbFo+2mrfc3i5IpkZVPbCPn9M+ 23GBkeQstzGBPkdBU6ZMimf0cfDlikm5d6GorK8MmjjFCW9vSgoqpcAaeso1vox4Djqf pZUg== X-Gm-Message-State: AGi0PubIs2OlQnXz5E1MzJ5k1Cv2o/awmozj9yIqrwKLyN2MOAMfm9PS pSqz8d/DQ+uAEHNOqQnNdUy42+b2GgU= X-Google-Smtp-Source: APiQypIAT+CGJxZBQkOF71h3rApmbBPSfw/uauIwzXB1+7IQzI3zr6l7afcLsuizMpkERWQDdusdVQ== X-Received: by 2002:a2e:9bc3:: with SMTP id w3mr1533530ljj.170.1587473432841; Tue, 21 Apr 2020 05:50:32 -0700 (PDT) Received: from localhost (109241244009.gdansk.vectranet.pl. [109.241.244.9]) by smtp.gmail.com with ESMTPSA id c21sm2073528lfh.16.2020.04.21.05.50.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Apr 2020 05:50:32 -0700 (PDT) From: =?utf-8?q?Micha=C5=82_Winiarski?= To: dri-devel@lists.freedesktop.org Subject: [PATCH] drm: Don't reserve minors for control nodes Date: Tue, 21 Apr 2020 14:49:22 +0200 Message-Id: <20200421124922.136191-1-michal@hardline.pl> X-Mailer: git-send-email 2.26.0 MIME-Version: 1.0 X-Mailman-Approved-At: Wed, 22 Apr 2020 06:54:41 +0000 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Sean Paul , Daniel Vetter , Marcin Bernatowicz , =?utf-8?q?Micha=C5=82_Wi?= =?utf-8?q?niarski?= Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Michał Winiarski Control nodes are no longer with us. While we still need to preserve render nodes numbering, there's no need to reserve the range formerly used for control. Let's repurpose it to be used by primary and remove control remains from the code entirely. References: 0d49f303e8a7 ("drm: remove all control node code") References: c9ac371d4b59 ("drm: Fix render node numbering regression from control node removal.") Signed-off-by: Michał Winiarski Cc: Daniel Vetter Cc: Eric Anholt Cc: Marcin Bernatowicz Cc: Sean Paul --- drivers/gpu/drm/drm_drv.c | 4 ++-- include/drm/drm_file.h | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c index c15c9b4540e1..366a760bbc29 100644 --- a/drivers/gpu/drm/drm_drv.c +++ b/drivers/gpu/drm/drm_drv.c @@ -124,8 +124,8 @@ static int drm_minor_alloc(struct drm_device *dev, unsigned int type) spin_lock_irqsave(&drm_minor_lock, flags); r = idr_alloc(&drm_minors_idr, NULL, - 64 * type, - 64 * (type + 1), + 128 * type, + 128 * (type + 1), GFP_NOWAIT); spin_unlock_irqrestore(&drm_minor_lock, flags); idr_preload_end(); diff --git a/include/drm/drm_file.h b/include/drm/drm_file.h index 716990bace10..45e6dae69293 100644 --- a/include/drm/drm_file.h +++ b/include/drm/drm_file.h @@ -54,7 +54,6 @@ struct file; */ enum drm_minor_type { DRM_MINOR_PRIMARY, - DRM_MINOR_CONTROL, DRM_MINOR_RENDER, };