Received: by 2002:a05:6500:1b45:b0:1f5:f2ab:c469 with SMTP id cz5csp844175lqb; Wed, 17 Apr 2024 12:22:28 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVuaAI39Zvb1eIe64VhlQBHMYAiK8Q/gfpbb2XGl1tQSB3bwfb5cD5GzEd4taTOXvkwUXi/U+ix1w5Pmh0gGUtW2aCju24OvmMcd6unQg== X-Google-Smtp-Source: AGHT+IHxo2BBhp0hWQV87ImQw9uVbA5BYkB5Crwnl+JyPQe4+CzxPWUjuKgLvml2k5elNZiK2RLV X-Received: by 2002:a17:90a:4885:b0:2a5:df97:b with SMTP id b5-20020a17090a488500b002a5df97000bmr88785pjh.18.1713381748645; Wed, 17 Apr 2024 12:22:28 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713381748; cv=pass; d=google.com; s=arc-20160816; b=RthHFxkMl9uN9Yh3x96G0Wl9VRB0Id26hCWxeRWP6Aoaw5dOWDhyYAx8/3kRuApplz 1fpdUj+/Jl3NdaMCzN4e0eN6mKZxUWbSHyM2P94bCCZ9q7Oq/2Xp5CiWTiifK4qHzpiO +atj8TPWhq7LjU3woHTsjrr3acRc/BScmgTtldc/Oj+IvarQkPv+4fihPZtsshrBB80+ LxPQzd9L9ljTnrbEHVK+L2XLnZRrE6K94itePpsz8iP/Wb0vmnBFTZxq+uTbWJor1klx suOrouCf9EE5U8GBC8QU6DBkdn9MWB/oZbiNK766e36iB0Z2pkNJVWR3Dc2bkyXHrIE5 FWqQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:from:subject:message-id :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :date:dkim-signature; bh=6Wzyp/UH0jiy8sQKjCgNes1kTmHnUc2aQBFCGoELS9Y=; fh=LaR6JkiBWF5dFFRu2LNPxHpfw8KtgS+hiczqnWJsob0=; b=D8rxz05DAaw0Ykf9G4UalHJkMVccIAekN5r5xM7Z5Lc9QUW+9b42YAbMYKm4WVyyRE qI6qQZW9J6HT37D8sDq5QnpqGFa7ua8T0/iGNXHLPkWOGanZMAt/CWhYHbqNslUNGbKo yKmzSMjTf8Vi1rKUUCXelVey4/Z3gHRy5ilusXcQAnXWQybAHBaXCx5qxg0c6G2z6WWQ qP3ixHTiLthhjUIltpa+dv9SK26MrR9Q2bf4Bns46u/+4Q3rUxYcuBFCqxlgtfRYx18a 9Lee+qtXj777V87rFoBoBW+0yLUvCfPJ7abfkjccEnMDEKaq+pekmriJO+ZZT+pemQIE p+pg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=ry4nIhtM; arc=pass (i=1 spf=pass spfdomain=flex--cmllamas.bounces.google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-149107-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-149107-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id a16-20020a17090ad81000b002a2d0de4884si1737676pjv.101.2024.04.17.12.22.28 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Apr 2024 12:22:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-149107-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=ry4nIhtM; arc=pass (i=1 spf=pass spfdomain=flex--cmllamas.bounces.google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-149107-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-149107-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com 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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 50BAA288D37 for ; Wed, 17 Apr 2024 19:14:49 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B6ECC23765; Wed, 17 Apr 2024 19:14:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="ry4nIhtM" Received: from mail-pj1-f73.google.com (mail-pj1-f73.google.com [209.85.216.73]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A708B1E895 for ; Wed, 17 Apr 2024 19:14:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.216.73 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713381283; cv=none; b=dm0LoICKytNk592B1bjVt62+Oauo5tOhczkcPwzg4ic7E+BnJP8ESrcTVvzywjgpCGz0B1xafF7YVIajEYALMJ71rpFnx00YZSGHf87yJHLE/MBNgXSbdHqGFErn8EiDXU6tEz9IXRZ8SnZnJSGfBWLPeyCWaXNYc7i1vk7NQsc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713381283; c=relaxed/simple; bh=j3qtkOvIu5NbbjZy+XtkB7ACU21ZGmO9yIcEK3aYMtA=; h=Date:Mime-Version:Message-ID:Subject:From:To:Cc:Content-Type; b=U3BLFQJG6GIsXYW7D9W3KH5mfOX2BLdPoixyIQgl+NRgIBvHzwjiBgGXbkW7VaVpOSOvpFfpACsc5OPamFOwlywTV2EtP0F1/r6ojLefIB9laX1wepu/WdUGCbFKEBm+aOKeJeEi/6ZTLJ37BWqTWZpwZr9eXYLp1UC1+BVYv5c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--cmllamas.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=ry4nIhtM; arc=none smtp.client-ip=209.85.216.73 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--cmllamas.bounces.google.com Received: by mail-pj1-f73.google.com with SMTP id 98e67ed59e1d1-2a482a2360aso1006936a91.0 for ; Wed, 17 Apr 2024 12:14:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1713381282; x=1713986082; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:from:subject:message-id :mime-version:date:from:to:cc:subject:date:message-id:reply-to; bh=6Wzyp/UH0jiy8sQKjCgNes1kTmHnUc2aQBFCGoELS9Y=; b=ry4nIhtMRSXi4o2wlTC7wqDebiNx6tsGS6nBBEGXp/g6FMW7vdBrWHXKuuZX6UPTha eSXMaC1sHJ2u4BTuh3uHOzqXfZPjzzKa0zbwXap2/vbhtz08LhPIzCsQPrUawKYR3GRn K5lfU7x5SMD5itmpwec3VqYSsnBLbUSozMOGwYFjgKRKMwsGGBxajE3JYrbI+SNdihOx fj93kDh0tCV8G/WfW7EDjpP1YlCzdbrpOVZPa+Benm9m2ePhPPWygPW5wOwemf8L1SYz DU+Uv5Q2J6U8tzP/25Wg27b2Rw7ZslTvcV94nDyTWgIGBOlgwIJOhP55Xsr2oRWNBQ6Q v7Iw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713381282; x=1713986082; h=content-transfer-encoding:cc:to:from:subject:message-id :mime-version:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=6Wzyp/UH0jiy8sQKjCgNes1kTmHnUc2aQBFCGoELS9Y=; b=kBgB3wB5SCu0YWH4TGl4mLAafkKy1ZH+xOPmE9h2buYX+AR96/VfBsVFzoG/7pPyqL 7fbW0MuXwcR2LmfcAoKsS6rO8Xc4kf6AnfleHllu7wGWrRmvRiuE++W2D/VduItkbfrQ 7JRY0PSIPEXibHICKgCXFLktx89Robc1xgDgFJoHSNX5xtVrD/c3zoFY4lB3UBEM9Zj9 uYcvaB2rpjt8qrMQh36O0WfM2VfHnAijzU77VWZxgN7yD/L6Jdsj/pB9mU68bjeXfRlj xqAfqIHpeH+7Q3vtF2cu1ZT4vGCjLxPZF5TjclyfxVOZIqqov18Ft7Rnjx+xyrlkr5Hj WtCg== X-Gm-Message-State: AOJu0YzBw/isYVz2gPYpav3pEncqaRHIquDxXEjAtUBxIzAFo7VLhanj PdWCCQY0NG+H+TMajbOm7Omlvr/qB/pLBNaQ0HccetNAwFcsYzbZjBq8zD9VXO5rYkz91ByCNvo 6ZWvEnTo1+w== X-Received: from xllamas.c.googlers.com ([fda3:e722:ac3:cc00:7f:e700:c0a8:5070]) (user=cmllamas job=sendgmr) by 2002:a17:90a:398e:b0:2aa:ab39:fcb6 with SMTP id z14-20020a17090a398e00b002aaab39fcb6mr669pjb.1.1713381280812; Wed, 17 Apr 2024 12:14:40 -0700 (PDT) Date: Wed, 17 Apr 2024 19:13:40 +0000 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 X-Mailer: git-send-email 2.44.0.683.g7961c838ac-goog Message-ID: <20240417191418.1341988-1-cmllamas@google.com> Subject: [PATCH 0/4] binder: optimize handle generation logic From: Carlos Llamas To: Greg Kroah-Hartman Cc: linux-kernel@vger.kernel.org, kernel-team@android.com, Alice Ryhl , Carlos Llamas , Tim Murray , "=?UTF-8?q?Arve=20Hj=C3=B8nnev=C3=A5g?=" , Martijn Coenen , Todd Kjos , John Stultz Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable This patchset adds the ability for userspace to select a faster handle generation logic. This is implemented through a new ioctl that enables certain functionality on a "per-proc" basis, this is required in order to maintain backwards compatibility. Cc: Tim Murray Cc: Arve Hj=C3=B8nnev=C3=A5g Cc: Alice Ryhl =20 Cc: Martijn Coenen Cc: Todd Kjos Cc: John Stultz Carlos Llamas (4): binder: introduce BINDER_SET_PROC_FLAGS ioctl binder: migrate ioctl to new PF_SPAM_DETECTION binder: add support for PF_LARGE_HANDLES binder: fix max_thread type inconsistency drivers/android/binder.c | 78 +++++++++++++++++++++++------ drivers/android/binder_internal.h | 10 ++-- include/uapi/linux/android/binder.h | 13 ++++- 3 files changed, 83 insertions(+), 18 deletions(-) --=20 2.44.0.683.g7961c838ac-goog