Return-Path: Date: Fri, 8 Oct 2010 08:16:42 -0700 (PDT) From: Mat Martineau To: linux-bluetooth@vger.kernel.org cc: marcel@holtmann.org, johan.hedberg@gmail.com, rshaffer@codeaurora.org, gustavo@padovan.org Subject: [PATCH] Use a valid PSM as the default in l2test. Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Sender: linux-bluetooth-owner@vger.kernel.org List-ID: ---------- Forwarded message ---------- Date: Wed, 4 Aug 2010 15:31:13 -0700 From: Mat Martineau To: linux-bluetooth@vger.kernel.org Cc: marcel@holtmann.org, johan.hedberg@gmail.com, rshaffer@codeaurora.org, Mat Martineau Subject: [PATCH] Use a valid PSM as the default in l2test. The Bluetooth spec requires PSMs to be odd numbers, with the least significant bit of the most significant byte set to 0. This change is a prerequisite for PSM validation in the kernel. --- test/l2test.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/test/l2test.c b/test/l2test.c index 0bb46f3..32cd27a 100644 --- a/test/l2test.c +++ b/test/l2test.c @@ -87,7 +87,7 @@ static long buffer_size = 2048; /* Default addr and psm */ static bdaddr_t bdaddr; -static unsigned short psm = 10; +static unsigned short psm = 0x1001; /* Default number of frames to send (-1 = infinite) */ static int num_frames = -1; -- 1.7.1 Ping. Marcel requested this patch to go with the "Validate PSM values in calls to connect() and bind()" change to the kernel code. -- Mat Martineau Employee of Qualcomm Innovation Center, Inc. Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum