Received: by 2002:a89:d88:0:b0:1fa:5c73:8e2d with SMTP id eb8csp439420lqb; Fri, 24 May 2024 03:14:32 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXErjKSJuD+Fd8eHm015NwuMVUuKQf+om5Pq1ougymWV7/mc1xhyKFLHP7vD7qrktxofBIbVO51XaY+YSDpJpzSXyL63oOH30yslw9AGA== X-Google-Smtp-Source: AGHT+IHgMbjkopjiH6KBXiqzlxNGj3O6A6BJsa/DXFFwxlMMRFJP41tny+DZvWYvWVS0NrCKYivd X-Received: by 2002:a17:902:e74d:b0:1e7:8d21:7fd7 with SMTP id d9443c01a7336-1f448705b0dmr23651165ad.28.1716545672075; Fri, 24 May 2024 03:14:32 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716545672; cv=pass; d=google.com; s=arc-20160816; b=CEWqMFmh9cO40xZ26KLqz/LBmfqTJmxmd9RKxnjO2zTh6An/vQzT7As1ti4Nxno6fY 2d8D0XIxENgmErk09vKQhjCmNZZTuzvk4811p3eRwxE8nude3SWxD3rW2X/4i4qYKoSV ogclPp5ELN6nTpwesswaxmT5QcEE5jUBl0Q14ZIgrv4I9HfElbiW8e4vX2T2s50e5zvj Oq3hX1/EWSJdt/JrZkZo/YnJBtj6WYyajT10yOTuDSiktRQIPSQL557wOzuQ+YObn1Qs 8CJW3qp3b+eQPiMZMtARPjxhC6LNQUUJKPLbM34uJZGVS1VC1JCO06pe03qQTb4Y3GQ8 Voeg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-disposition:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:message-id:subject:cc:to:from:date :dkim-signature; bh=IM+l9b+Ddr6zhT1mzkxDkWWP6YYG+wKMelFtyjWWBDQ=; fh=W338fFR3ZiWGeKQvAa8vNwDaGoqO9NTLxSwXr9xETeY=; b=vzDGdFp3TYv6fMm/l0I17d5YQezgz9CBW/UrHNddnwOg6rL3lXXxVFoRb+xak1JQV4 UbrgEhhlNB9Hvw66tzRY4Js+MUeEnjeXyYfIWMBFKnUY2KGIOWaCOxiNSAGN5dyVcOI4 UrM2LZHWpdiELgsmvP3qDKNvCgnLUw7fa5aJ0jSBww5qBcNUDWAUxlV5hNAYJF3FSAWH LlF005r/2gC5Vf3c4iH/sOZfn26QYMcQXvVXkpTJqR5TXJ47fioHkQ2GJmSOkExt/RyZ sNQFL9UZLXBnIEXvgnQsjfyF1YavMYn8tA/fcbWuWtUWTo6H6ywuc2eP1mFcLjrdFi78 7QUw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NIhCGedn; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-bluetooth+bounces-4923-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-bluetooth+bounces-4923-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id d9443c01a7336-1f44c99c871si10934325ad.384.2024.05.24.03.14.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 24 May 2024 03:14:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-bluetooth+bounces-4923-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NIhCGedn; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-bluetooth+bounces-4923-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-bluetooth+bounces-4923-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.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 sy.mirrors.kernel.org (Postfix) with ESMTPS id D33E1B21849 for ; Fri, 24 May 2024 10:14:20 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C96988593C; Fri, 24 May 2024 10:14:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="NIhCGedn" X-Original-To: linux-bluetooth@vger.kernel.org Received: from mail-wm1-f43.google.com (mail-wm1-f43.google.com [209.85.128.43]) (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 A3ECC85927 for ; Fri, 24 May 2024 10:14:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.43 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716545650; cv=none; b=VwIQgvxmTA+ZzaLU9rsDPmlpbaYVOE7lVwg8K4StwYD/qo+5b1HGg4a/1X7Ftr6TnMvBtvNo8P7Gevq0F9zlQXEclPodxheF376Isbn24/fT9wMG8amjZpTr6i36yI09gOOShls5PYKcR39l7Xcovs2EktBmBJ70y7oQcAOjVxQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716545650; c=relaxed/simple; bh=sDQFYTVbNT2/K9iVIl5y4i/52Li/sV3v7epjRryjwUc=; h=Date:From:To:Cc:Subject:Message-ID:MIME-Version:Content-Type: Content-Disposition; b=M8MypFrm7mwcrjyO08a9zhGd+k3cF3M3XiZhI/CAFr3DvaWd5I5lDiTFFma7WlKcoSUAjRsB4WIDZgsCUWR6HaD1VeZjKfX4pR2VL4GJwoorKTH6/IGAJK95PWJUVOHYldpWtFRQ+yAVM7XJvFPAE3DC7WbaEQ5eVrwKyucw3dk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=NIhCGedn; arc=none smtp.client-ip=209.85.128.43 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-wm1-f43.google.com with SMTP id 5b1f17b1804b1-4200ee78f33so30459575e9.3 for ; Fri, 24 May 2024 03:14:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1716545647; x=1717150447; darn=vger.kernel.org; h=content-disposition:mime-version:message-id:subject:cc:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=IM+l9b+Ddr6zhT1mzkxDkWWP6YYG+wKMelFtyjWWBDQ=; b=NIhCGednBxy/TivUBT20zMCtZTtJE2oeeglyMkW8Lx+QRDznGRUa3ntltDS30L22fp XGjjpAvx3B+SXCVH9z+VvvU8rnu8cEoiGURcCfppYw8UB76P/IL8UHgzJxeUY/mgtzib AeRJV2TYl88rame2w6i9cvFWevaMNrR+p6tGlyvoa+MjIVpVNx5RHUXIY3B35nWLz06c G4i3A85kfzEx8rNKns3L4jL9G9YwEuXsmpGcCmaX8RvzJidjeE6ZgEu78/oAxHb38iNd OOWeAesmljUOnu+X/X+e7o88IkUC2fn8WxE3cKQAsXcRPbK+/PoN6dW9GcBzBlWQHGGL AiAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716545647; x=1717150447; h=content-disposition:mime-version:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=IM+l9b+Ddr6zhT1mzkxDkWWP6YYG+wKMelFtyjWWBDQ=; b=e+vYCBze+xNXLitmrl21mFYZIYeRrSiiKx68IYEn5ixPT62OdjTFAEQoAcQJONZp88 EhwJKLqwOMvM6Rkd0RZXjVS7zK3e6MOZRS/asfm/rxOSrUImZ2iBW+hIPmBkO0jCIkwu ttrm7OoYVWVwDg+h+db1kqGeEAQgDKmD2doyFm7W11GSI/Ol6YYCTtOAxtrhN9eAeGGh elDbViEqS3RC+zUM7l8oGhR20LJEKLDckeh70jR89mUhKRbYXg9+gp5xmgfh/h5e3sKW pdLjqDAsOe0GX59boPT5EuCbZWDxnBiZ58NkaBlmD4oyQfiOHcGol0Yka5riNZSewh/Y 1ejg== X-Forwarded-Encrypted: i=1; AJvYcCUbDJKcJKQV5uoQupwDv0GhIW9MuCl+0k5mmtEMpi9zMRSJxkl4zDxlUokSJNuEycCVFizhka44apvW0vCoAIi7JRogeH3/ejiUaZsqN8RT X-Gm-Message-State: AOJu0YwKzWlaLtusgcIZDOUznU1Jyyv57ZlACCaKHZY4Gqpzxu2EugIO jcYIF9RC0FLPqMonW0cbPuZhF6GOwz9onxWvav3HuektWyU8IxT8vaRolZcAI3A= X-Received: by 2002:a05:600c:444e:b0:420:14fb:de1f with SMTP id 5b1f17b1804b1-42108a5965fmr11697145e9.14.1716545646781; Fri, 24 May 2024 03:14:06 -0700 (PDT) Received: from localhost ([102.222.70.76]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-42100f759f0sm48224445e9.28.2024.05.24.03.14.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 24 May 2024 03:14:06 -0700 (PDT) Date: Fri, 24 May 2024 13:14:02 +0300 From: Dan Carpenter To: Luiz Augusto von Dentz Cc: Marcel Holtmann , Johan Hedberg , Luiz Augusto von Dentz , linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [PATCH] Bluetooth: MGMT: Uninitialized variable in load_conn_param() Message-ID: <819ed9b8-8790-4d15-b2a0-20929328d582@moroto.mountain> Precedence: bulk X-Mailing-List: linux-bluetooth@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Mailer: git-send-email haha only kidding The "update" variable needs to be initialized to false. Fixes: 831be422f3bb ("Bluetooth: MGMT: Make MGMT_OP_LOAD_CONN_PARAM update existing connection") Signed-off-by: Dan Carpenter --- net/bluetooth/mgmt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c index 20eca8a9c681..3ab1558ff391 100644 --- a/net/bluetooth/mgmt.c +++ b/net/bluetooth/mgmt.c @@ -7865,8 +7865,8 @@ static int load_conn_param(struct sock *sk, struct hci_dev *hdev, void *data, struct mgmt_conn_param *param = &cp->params[i]; struct hci_conn_params *hci_param; u16 min, max, latency, timeout; + bool update = false; u8 addr_type; - bool update; bt_dev_dbg(hdev, "Adding %pMR (type %u)", ¶m->addr.bdaddr, param->addr.type); -- 2.43.0