get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/2218366/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 2218366,
    "url": "http://patchwork.ozlabs.org/api/patches/2218366/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/hostap/patch/20260401054901.3780435-21-peddolla.reddy@oss.qualcomm.com/",
    "project": {
        "id": 22,
        "url": "http://patchwork.ozlabs.org/api/projects/22/?format=api",
        "name": "HostAP Development",
        "link_name": "hostap",
        "list_id": "hostap.lists.infradead.org",
        "list_email": "hostap@lists.infradead.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": "",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20260401054901.3780435-21-peddolla.reddy@oss.qualcomm.com>",
    "list_archive_url": null,
    "date": "2026-04-01T05:48:58",
    "name": "[RFC,20/23] PR: Extend PR_PASN_START ctrl iface with full ranging parameters",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "7d784d7a78974f37b31e366bcfbdf29a61729205",
    "submitter": {
        "id": 93026,
        "url": "http://patchwork.ozlabs.org/api/people/93026/?format=api",
        "name": "Peddolla Harshavardhan Reddy",
        "email": "peddolla.reddy@oss.qualcomm.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/hostap/patch/20260401054901.3780435-21-peddolla.reddy@oss.qualcomm.com/mbox/",
    "series": [
        {
            "id": 498276,
            "url": "http://patchwork.ozlabs.org/api/series/498276/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/hostap/list/?series=498276",
            "date": "2026-04-01T05:48:44",
            "name": "PR: Add nl80211 support and ranging for Proximity Detection",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/498276/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/2218366/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/2218366/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "\n <hostap-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org>",
        "X-Original-To": "incoming@patchwork.ozlabs.org",
        "Delivered-To": "patchwork-incoming@legolas.ozlabs.org",
        "Authentication-Results": [
            "legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n secure) header.d=lists.infradead.org header.i=@lists.infradead.org\n header.a=rsa-sha256 header.s=bombadil.20210309 header.b=wGhiCvqQ;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n unprotected) header.d=qualcomm.com header.i=@qualcomm.com header.a=rsa-sha256\n header.s=qcppdkim1 header.b=Uf/eu1KG;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n unprotected) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com\n header.a=rsa-sha256 header.s=google header.b=Rug5FgiI;\n\tdkim-atps=neutral",
            "legolas.ozlabs.org;\n spf=none (no SPF record) smtp.mailfrom=lists.infradead.org\n (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org;\n envelope-from=hostap-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org;\n receiver=patchwork.ozlabs.org)"
        ],
        "Received": [
            "from bombadil.infradead.org (bombadil.infradead.org\n [IPv6:2607:7c80:54:3::133])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4flvHF6m0Hz1yGH\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 01 Apr 2026 16:51:05 +1100 (AEDT)",
            "from localhost ([::1] helo=bombadil.infradead.org)\n\tby bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux))\n\tid 1w7oTJ-0000000E1Zf-0d5A;\n\tWed, 01 Apr 2026 05:50:33 +0000",
            "from mx0a-0031df01.pphosted.com ([205.220.168.131])\n\tby bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux))\n\tid 1w7oSz-0000000E173-32Of\n\tfor hostap@lists.infradead.org;\n\tWed, 01 Apr 2026 05:50:15 +0000",
            "from pps.filterd (m0279866.ppops.net [127.0.0.1])\n\tby mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id\n 6315ghvK1831876\n\tfor <hostap@lists.infradead.org>; Wed, 1 Apr 2026 05:50:13 GMT",
            "from mail-pl1-f199.google.com (mail-pl1-f199.google.com\n [209.85.214.199])\n\tby mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4d8equc55s-1\n\t(version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT)\n\tfor <hostap@lists.infradead.org>; Wed, 01 Apr 2026 05:50:12 +0000 (GMT)",
            "by mail-pl1-f199.google.com with SMTP id\n d9443c01a7336-2b2454fc131so92625955ad.3\n        for <hostap@lists.infradead.org>;\n Tue, 31 Mar 2026 22:50:12 -0700 (PDT)",
            "from hu-peddolla-hyd.qualcomm.com ([202.46.23.25])\n        by smtp.gmail.com with ESMTPSA id\n d9443c01a7336-2b24268aa4fsm129919665ad.36.2026.03.31.22.50.10\n        (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n        Tue, 31 Mar 2026 22:50:11 -0700 (PDT)"
        ],
        "DKIM-Signature": [
            "v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;\n\td=lists.infradead.org; s=bombadil.20210309; h=Sender:\n\tContent-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post:\n\tList-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:\n\tMessage-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description:\n\tResent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:\n\tList-Owner; bh=6VbA34LClHEkLY0tx4l36Y9s9T0y+z8gi9o1v02r2rE=; b=wGhiCvqQTMvVY1\n\tMB9A9Oo7QQH+b3L+IPUi0Rx0jK529MKPMVI4Rag/kL/YSs1KGDBSGr/J7dln4DC9/ZKa/ubgRikFx\n\tEpbIB7zhG25zmR3tBuJ+VJRKV6V5vb0Z+Lo6/Mat9EjQmvV+j4Vmg0l6mrqznOR+yBXfN9LGrZBEV\n\tcPAfrmoXDeUWlXGU05XiMCHZ56itDS39mLOZ7kGqvpIfGUFFdze/gEfpnRRKsvwC50RTqrkr9phNN\n\tOVsTjaxNl7JBt/zj15l6nckFj/kckwi1QdWIp937i1XoDgZUSQgj9yai6k21admNfIca1tUDaaHfl\n\t7RyqMNGml3WbATtOiaJA==;",
            "v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h=\n\tcc:content-transfer-encoding:date:from:in-reply-to:message-id\n\t:mime-version:references:subject:to; s=qcppdkim1; bh=J+OjbOaX9+m\n\tXcAfkM6HBZUJQh6E5Y34iAcn/al98bSI=; b=Uf/eu1KGNNKjLaY5CGaN1hUa+Tx\n\th+EQr6R8wHRTaXYu4MyA6f8bnwUsj5qoHK/qM+JygyXkaEfB2SvxTBzcIhhEHhsD\n\tUDcrvhYhu1PAoU4endB7BPwcTXJnn5ICLIlIOHAxI2wc4zFPivk5mdTi4DjvlyZf\n\t6fR0RkN/hrTnA84rcB+VMb3D3nuogevsEkGlDhVMrGIZ59bVQtv6YIvjCvehPNRI\n\tYrrg1Z13I3b3N0ylrD9J1KIvkPD7bRfM4y1ZMPcgVokSEA4l47pK9XuC7/Hd2t+Y\n\trgykuuBMGOJYAa5ez2vHHb+D7sjsX3f2JaUFGFzZa6yCw1NawIAPnZP34qA==",
            "v=1; a=rsa-sha256; c=relaxed/relaxed;\n        d=oss.qualcomm.com; s=google; t=1775022612; x=1775627412;\n darn=lists.infradead.org;\n        h=content-transfer-encoding:mime-version:references:in-reply-to\n         :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n         :message-id:reply-to;\n        bh=J+OjbOaX9+mXcAfkM6HBZUJQh6E5Y34iAcn/al98bSI=;\n        b=Rug5FgiIVI4KJ1Qha/5yKfosZDpCzGvS0xhPJG4Z8mU+yIzxkrL2j4Da0nOHkIduvI\n         BUEy5It1ioH3w+Y9IgrOO4yIKxLt60NFGFaAq/t6OvJ96GBf8UKYyQwfxpvtmMSrPZZ9\n         rMcHYYJHo0sX2fnkZ+V2ZA176Vi4YDMBtkPO0xAFhzcXnB5m2oF4sN1ziKFWlLoXlGgX\n         FAYgIBCUDdficweDb5zatCipEebfcNcpjuUOlE88uOkIGs1/Cn5oK1bCxaF4ZUIvc7mH\n         wSQt9aX+aK4NffpkboTFeHuCC3HEBLpCK5NqFlmzVVUyqO+IMiipUAgXl+6F/TC1uqEp\n         gGfw=="
        ],
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n        d=1e100.net; s=20251104; t=1775022612; x=1775627412;\n        h=content-transfer-encoding:mime-version:references:in-reply-to\n         :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n         :to:cc:subject:date:message-id:reply-to;\n        bh=J+OjbOaX9+mXcAfkM6HBZUJQh6E5Y34iAcn/al98bSI=;\n        b=aDaA+sGcwnvXi/AmnZHJmW+SzGGbbZYv3qz6zSIAD0OMzoonRnjTLfeyIWFw5AgFSm\n         sSR5e7UAJGSpY7hBRhLTxxALA+UH1Z0QTTPFkzg8ZQ1vP3VEi3odaDQhYJzHcrU013AN\n         ac93kRYNVWEoe2NzdJZd57B+JGAnKI4NMDjviiWl3RKaFbsekB6DW7HqX7LE2d2WPm7o\n         z0kCTg2x2liyVHVPLDR0+T/dZ+HWVKcBZ8BPc5WmjsES9t+Llr06rNiBzWFjjaV35m6y\n         UsHZggUzI1GYjTxudEdObVcGkdBTU6skDBHMLcjPPgItjJ6nMWVCMISbj1izijQ65lIF\n         gAuA==",
        "X-Gm-Message-State": "AOJu0Ywc91enxZEV74/mtCZVLeTLiGQDtB3PvYOhFECfU4n7DCaakQQ5\n\tjfZ7s5ZpezeJUhHqnA9kX58ucoX3zI6dsCFp7p80yjS7ULK+er+9hXfTDudddsO4q3apt6AGOEq\n\tDlycDmcaq+VOi0LaD5jBGDtSm0loReUoV1cMdxBsc1yzI3oqrlFbWnUNuVFWpjvskmzn7m3I=",
        "X-Gm-Gg": "ATEYQzyytXqR2sQfy7XFWs8O9ufcWXUSTavUCHy9gAsJJL1YvlZVB+/N8RA/vDaZFNu\n\t4uZjmSemIiwRKH8OMlDG1++pxrx8u/VCINq9IN5c2wK22J+84+UB03Y3QdwROXs+W45X5nhaDpA\n\tMH7livMpEu4npTDM2jh9qrC/htNY4KPQevvS43Wh9WiSTc7+9ItlpdBVInW55Z29sxjtQTGaAWJ\n\tnj8yYX4SWw9iBF3o2XR6/VO+mbOD043QtXfkOPEQJTAD6Fu5ho6S+JlT9pt5aip3Mtsj8t1RUnO\n\tSMnp4WS1zwggmHQB2xV/lm+yARfDt2Pht6kHGZVrEZZ6dtMf95wpKOnTZpyS5Vu3DdGAkWesPSl\n\toY9oxlAlpWds2N0xCZKyjthf70tmKp3DbWzuKWU2yQsYez1cJfLuAVU8=",
        "X-Received": [
            "by 2002:a17:903:22d2:b0:2b0:5b4e:370c with SMTP id\n d9443c01a7336-2b269ccca40mr22717115ad.32.1775022611936;\n        Tue, 31 Mar 2026 22:50:11 -0700 (PDT)",
            "by 2002:a17:903:22d2:b0:2b0:5b4e:370c with SMTP id\n d9443c01a7336-2b269ccca40mr22716785ad.32.1775022611430;\n        Tue, 31 Mar 2026 22:50:11 -0700 (PDT)"
        ],
        "From": "Peddolla Harshavardhan Reddy <peddolla.reddy@oss.qualcomm.com>",
        "To": "hostap@lists.infradead.org",
        "Cc": "vjakkam@qti.qualcomm.com",
        "Subject": "[RFC PATCH 20/23] PR: Extend PR_PASN_START ctrl iface with full\n ranging parameters",
        "Date": "Wed,  1 Apr 2026 11:18:58 +0530",
        "Message-Id": "<20260401054901.3780435-21-peddolla.reddy@oss.qualcomm.com>",
        "X-Mailer": "git-send-email 2.34.1",
        "In-Reply-To": "<20260401054901.3780435-1-peddolla.reddy@oss.qualcomm.com>",
        "References": "<20260401054901.3780435-1-peddolla.reddy@oss.qualcomm.com>",
        "MIME-Version": "1.0",
        "X-Proofpoint-Spam-Details-Enc": "AW1haW4tMjYwNDAxMDA0OCBTYWx0ZWRfX7lDcm03zpSPM\n jN/fkAUY03Ot3fwO0tuRK3xSf3FOiTFjfRibd+bfCrVVjQdMInvCb4MSngtQyq5AnG/XxnIfSib\n 7KpKHk/3pQgkdzrv/MnEPVJzoccqbjtUwGvW58iEXM0QOIW7dhj1VBAOTwWOPfjBnLQSeIHo+8u\n scNOtyTRJY6HGmTX2/nDiFnBEV+5JEkaV5QsKfjH676K+Gy6Wn0zCNVcitB4+3RAwn+4qmarwCK\n gAy+hp+SAA1BaGG7eDR/uZlR0v5jbBnNMnEjjSAlaA5P/9RyoPsLDb9ba/lyqkHXsVy4sDFg1uE\n 2DT0DLcq2unq0827hKb4qDRRgEl+cksKr5KnuVihh4l8gJmG9XSM4NUu/PaXRttHF7xdNh7Ogrg\n CuCc9bQjDcNpSGzRZjQXHT8cW4UIROVvnpP9xWnxMrZ622c43COgaMLxhF3qXazVroC4JV1YAH+\n ENp818ZN47I5PfhGdvQ==",
        "X-Proofpoint-GUID": "yzCxbNr_9dTxpW3BGunIXmhrfXIdqFl2",
        "X-Proofpoint-ORIG-GUID": "yzCxbNr_9dTxpW3BGunIXmhrfXIdqFl2",
        "X-Authority-Analysis": "v=2.4 cv=YMOSCBGx c=1 sm=1 tr=0 ts=69ccb214 cx=c_pps\n a=JL+w9abYAAE89/QcEU+0QA==:117 a=ZePRamnt/+rB5gQjfz0u9A==:17\n a=A5OVakUREuEA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22\n a=u7WPNUs3qKkmUXheDGA7:22 a=YMgV9FUhrdKAYTUUvYB2:22 a=EUspDBNiAAAA:8\n a=s-j-xAy49_O8sVNg-RMA:9 a=324X-CrmTo6CU4MGRt3R:22",
        "X-Proofpoint-Virus-Version": "vendor=baseguard\n engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.51,FMLib:17.12.100.49\n definitions=2026-04-01_02,2026-03-31_02,2025-10-01_01",
        "X-Proofpoint-Spam-Details": "rule=outbound_notspam policy=outbound score=0\n priorityscore=1501 clxscore=1015 spamscore=0 impostorscore=0 adultscore=0\n lowpriorityscore=0 bulkscore=0 phishscore=0 malwarescore=0 suspectscore=0\n classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0\n reason=mlx scancount=1 engine=8.22.0-2603050001 definitions=main-2604010048",
        "X-CRM114-Version": "20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 ",
        "X-CRM114-CacheID": "sfid-20260331_225013_806606_6BA3D4E2 ",
        "X-CRM114-Status": "GOOD (  17.84  )",
        "X-Spam-Score": "0.2 (/)",
        "X-Spam-Report": "Spam detection software,\n running on the system \"bombadil.infradead.org\",\n has NOT identified this incoming email as spam.  The original\n message has been attached to this so you can view it or label\n similar future email.  If you have any questions, see\n the administrator of that system for details.\n Content preview:  Currently,\n the PR_PASN_START control interface command calls\n    wpas_pr_initiate_pasn_auth() directly with a small fixed set of\n parameters,\n    making it impossible to configure the ranging session beyond ba [...]\n Content analysis details:   (0.2 points, 5.0 required)\n  pts rule name              description\n ---- ----------------------\n --------------------------------------------------\n -0.7 RCVD_IN_DNSWL_LOW      RBL: Sender listed at https://www.dnswl.org/, low\n                             trust\n                             [205.220.168.131 listed in list.dnswl.org]\n  1.0 RCVD_IN_VALIDITY_RPBL_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to\n                              Validity was blocked.  See\n                             https://knowledge.validity.com/hc/en-us/articles/20961730681243\n                              for more information.\n                           [205.220.168.131 listed in\n bl.score.senderscore.com]\n  1.0 RCVD_IN_VALIDITY_CERTIFIED_BLOCKED RBL: ADMINISTRATOR NOTICE: The\n                             query to Validity was blocked.  See\n                             https://knowledge.validity.com/hc/en-us/articles/20961730681243\n                              for more information.\n                        [205.220.168.131 listed in\n sa-trusted.bondedsender.org]\n  1.0 RCVD_IN_VALIDITY_SAFE_BLOCKED RBL: ADMINISTRATOR NOTICE: The query to\n                              Validity was blocked.  See\n                             https://knowledge.validity.com/hc/en-us/articles/20961730681243\n                              for more information.\n                             [205.220.168.131 listed in\n sa-accredit.habeas.com]\n  0.0 SPF_HELO_NONE          SPF: HELO does not publish an SPF Record\n -0.0 SPF_PASS               SPF: sender matches SPF record\n  0.1 DKIM_SIGNED            Message has a DKIM or DK signature,\n not necessarily valid\n -0.1 DKIM_VALID_EF          Message has a valid DKIM or DK signature from\n                             envelope-from domain\n -0.1 DKIM_VALID_AU          Message has a valid DKIM or DK signature from\n author's\n                             domain\n -0.1 DKIM_VALID             Message has at least one valid DKIM or DK\n signature\n -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%\n                             [score: 0.0000]",
        "X-BeenThere": "hostap@lists.infradead.org",
        "X-Mailman-Version": "2.1.34",
        "Precedence": "list",
        "List-Id": "<hostap.lists.infradead.org>",
        "List-Unsubscribe": "<http://lists.infradead.org/mailman/options/hostap>,\n <mailto:hostap-request@lists.infradead.org?subject=unsubscribe>",
        "List-Archive": "<http://lists.infradead.org/pipermail/hostap/>",
        "List-Post": "<mailto:hostap@lists.infradead.org>",
        "List-Help": "<mailto:hostap-request@lists.infradead.org?subject=help>",
        "List-Subscribe": "<http://lists.infradead.org/mailman/listinfo/hostap>,\n <mailto:hostap-request@lists.infradead.org?subject=subscribe>",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Sender": "\"Hostap\" <hostap-bounces@lists.infradead.org>",
        "Errors-To": "hostap-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org"
    },
    "content": "Currently, the PR_PASN_START control interface command calls\nwpas_pr_initiate_pasn_auth() directly with a small fixed set\nof parameters, making it impossible to configure the ranging\nsession beyond basic PASN authentication.\n\nRefactor wpas_ctrl_iface_pr_pasn_start() to build a\npr_pasn_ranging_params structure and route through\nwpas_pr_pasn_trigger(), which performs capability validation\nbefore initiating PASN. Extend the command to accept EDCA\nburst parameters (burst_period, num_bursts_exp, ftms_per_burst,\nftmr_retries, burst_duration), NTB availability window settings\n(min/max_time_between_meas, availability_window, nominal_time,\nmeasurements_per_aw), proximity thresholds (ingress_threshold,\negress_threshold), lmr_feedback, pd_suppress_results, and a\ncontinuous_session_time for session lifetime control.\n\nSigned-off-by: Peddolla Harshavardhan Reddy <peddolla.reddy@oss.qualcomm.com>\n---\n wpa_supplicant/ctrl_iface.c | 93 +++++++++++++++++++++++++------------\n 1 file changed, 64 insertions(+), 29 deletions(-)",
    "diff": "diff --git a/wpa_supplicant/ctrl_iface.c b/wpa_supplicant/ctrl_iface.c\nindex 6412c5278..e971db3d6 100644\n--- a/wpa_supplicant/ctrl_iface.c\n+++ b/wpa_supplicant/ctrl_iface.c\n@@ -11556,65 +11556,98 @@ static int wpas_ctrl_iface_pr_pasn_start(struct wpa_supplicant *wpa_s,\n \t\t\t\t\t char *cmd)\n {\n \tchar *token, *context = NULL;\n-\tu8 addr[ETH_ALEN];\n-\tint freq = 0, forced_pr_freq = 0;\n-\tu8 ranging_type = 0, role = 0, auth_mode = 0;\n+\tstruct pr_pasn_ranging_params params;\n \tbool got_addr = false;\n-\tu8 src_addr[ETH_ALEN], *p_src_addr = NULL;\n-\tenum pr_pasn_role pasn_role = PR_ROLE_PASN_INITIATOR;\n+\n+\tos_memset(&params, 0, sizeof(params));\n+\tparams.action = PR_PASN_AND_RANGING;\n \n \twhile ((token = str_token(cmd, \" \", &context))) {\n \t\tif (os_strncmp(token, \"addr=\", 5) == 0) {\n-\t\t\tif (hwaddr_aton(token + 5, addr))\n+\t\t\tif (hwaddr_aton(token + 5, params.peer_addr))\n \t\t\t\treturn -1;\n \t\t\tgot_addr = true;\n \t\t} else if (os_strcmp(token, \"role=ISTA\") == 0) {\n-\t\t\trole |= PR_ISTA_SUPPORT;\n+\t\t\tparams.ranging_role |= PR_ISTA_SUPPORT;\n \t\t} else if (os_strcmp(token, \"role=RSTA\") == 0) {\n-\t\t\trole |= PR_RSTA_SUPPORT;\n+\t\t\tparams.ranging_role |= PR_RSTA_SUPPORT;\n \t\t} else if (os_strcmp(token, \"ranging_type=EDCA\") == 0) {\n-\t\t\tranging_type |= PR_EDCA_BASED_RANGING;\n+\t\t\tparams.ranging_type |= PR_EDCA_BASED_RANGING;\n \t\t} else if (os_strcmp(token, \"ranging_type=NTB-OPEN-PHY\") == 0) {\n-\t\t\tranging_type |= PR_NTB_OPEN_BASED_RANGING;\n+\t\t\tparams.ranging_type |= PR_NTB_OPEN_BASED_RANGING;\n \t\t} else if (os_strcmp(token, \"ranging_type=NTB-SEC-PHY\") == 0) {\n-\t\t\tranging_type |= PR_NTB_SECURE_LTF_BASED_RANGING;\n+\t\t\tparams.ranging_type |= PR_NTB_SECURE_LTF_BASED_RANGING;\n \t\t} else if (os_strncmp(token, \"freq=\", 5) == 0) {\n-\t\t\tfreq = atoi(token + 5);\n+\t\t\tparams.freq = atoi(token + 5);\n \t\t} else if (os_strncmp(token, \"auth=\", 5) == 0) {\n-\t\t\tauth_mode = atoi(token + 5);\n+\t\t\tparams.auth_mode = atoi(token + 5);\n \t\t} else if (os_strncmp(token, \"forced_pr_freq=\", 15) == 0) {\n-\t\t\tforced_pr_freq = atoi(token + 15);\n+\t\t\tparams.forced_pr_freq = atoi(token + 15);\n+\t\t} else if (os_strncmp(token, \"burst_period=\", 13) == 0) {\n+\t\t\tparams.burst_period = atoi(token + 13);\n+\t\t} else if (os_strncmp(token, \"num_bursts_exp=\", 15) == 0) {\n+\t\t\tparams.num_bursts_exp = atoi(token + 15);\n+\t\t} else if (os_strncmp(token, \"ftms_per_burst=\", 15) == 0) {\n+\t\t\tparams.ftms_per_burst = atoi(token + 15);\n+\t\t} else if (os_strncmp(token, \"ftmr_retries=\", 13) == 0) {\n+\t\t\tparams.ftmr_retries = atoi(token + 13);\n+\t\t} else if (os_strncmp(token, \"burst_duration=\", 15) == 0) {\n+\t\t\tparams.burst_duration = atoi(token + 15);\n+\t\t} else if (os_strncmp(token, \"min_time_between_meas=\", 22) == 0) {\n+\t\t\tparams.min_time_between_measurements = atoi(token + 22);\n+\t\t} else if (os_strncmp(token, \"max_time_between_meas=\", 22) == 0) {\n+\t\t\tparams.max_time_between_measurements = atoi(token + 22);\n+\t\t} else if (os_strncmp(token, \"availability_window=\", 20) == 0) {\n+\t\t\tparams.availability_window = atoi(token + 20);\n+\t\t} else if (os_strncmp(token, \"nominal_time=\", 13) == 0) {\n+\t\t\tparams.nominal_time = atoi(token + 13);\n+\t\t} else if (os_strncmp(token, \"measurements_per_aw=\", 20) == 0) {\n+\t\t\tparams.measurements_per_aw = atoi(token + 20);\n+\t\t} else if (os_strcmp(token, \"request_lci=1\") == 0) {\n+\t\t\tparams.request_lci = true;\n+\t\t} else if (os_strcmp(token, \"request_civicloc=1\") == 0) {\n+\t\t\tparams.request_civicloc = true;\n+\t\t} else if (os_strncmp(token, \"continuous_session_time=\", 24) == 0) {\n+\t\t\tparams.continuous_ranging_session_time = atoi(token + 24);\n \t\t} else if (os_strncmp(token, \"src_addr=\", 9) == 0) {\n-\t\t\tif (hwaddr_aton(token + 9, src_addr))\n+\t\t\tif (hwaddr_aton(token + 9, params.src_addr))\n \t\t\t\treturn -1;\n-\t\t\tp_src_addr = src_addr;\n \t\t} else if (os_strcmp(token, \"pasn_role=INITIATOR\") == 0) {\n-\t\t\tpasn_role = PR_ROLE_PASN_INITIATOR;\n+\t\t\tparams.pasn_role = PR_ROLE_PASN_INITIATOR;\n \t\t} else if (os_strcmp(token, \"pasn_role=RESPONDER\") == 0) {\n-\t\t\tpasn_role = PR_ROLE_PASN_RESPONDER;\n+\t\t\tparams.pasn_role = PR_ROLE_PASN_RESPONDER;\n+\t\t} else if (os_strcmp(token, \"lmr_feedback=1\") == 0) {\n+\t\t\tparams.lmr_feedback = true;\n+\t\t} else if (os_strncmp(token, \"ingress_threshold=\", 18) == 0) {\n+\t\t\tparams.ingress_threshold = atoll(token + 18);\n+\t\t} else if (os_strncmp(token, \"egress_threshold=\", 17) == 0) {\n+\t\t\tparams.egress_threshold = atoll(token + 17);\n+\t\t} else if (os_strcmp(token, \"pd_suppress_results=1\") == 0) {\n+\t\t\tparams.pr_suppress_results = true;\n \t\t} else {\n \t\t\twpa_printf(MSG_DEBUG,\n-\t\t\t\t   \"CTRL: PASN invalid parameter: '%s'\",\n+\t\t\t\t   \"CTRL: PR_PASN_START invalid parameter: '%s'\",\n \t\t\t\t   token);\n \t\t\treturn -1;\n \t\t}\n \t}\n \n-\tif (!got_addr || ranging_type == 0 || role == 0 || freq == 0) {\n+\tif (!got_addr || params.ranging_type == 0 || params.ranging_role == 0 ||\n+\t    params.freq == 0) {\n \t\twpa_printf(MSG_DEBUG,\n-\t\t\t   \"CTRL: Proximity Ranging PASN missing parameter\");\n+\t\t\t   \"CTRL: PR_PASN_START missing parameter\");\n \t\treturn -1;\n \t}\n \n \twpa_printf(MSG_DEBUG,\n-\t\t   \"CTRL: PR PASN params: ranging type=0x%x, role=0x%x, \"\n-\t\t   \"pasn_role=%d, auth_mode=%d, forced pr freq=%d, addr=\"\n-\t\t   MACSTR \" src_addr=\" MACSTR,\n-\t\t   ranging_type, role, pasn_role, auth_mode, forced_pr_freq,\n-\t\t   MAC2STR(addr), MAC2STR(p_src_addr ? p_src_addr : addr));\n-\treturn wpas_pr_initiate_pasn_auth(wpa_s, addr, freq, auth_mode, role,\n-\t\t\t\t\t  ranging_type, forced_pr_freq,\n-\t\t\t\t\t  p_src_addr, pasn_role);\n+\t\t   \"CTRL: PR_PASN_START params: ranging type=0x%x, role=0x%x,\"\n+\t\t   \" auth_mode=%d, freq=%d, addr=\" MACSTR \" src_addr=\" MACSTR \" pasn_role=%d\",\n+\t\t   params.ranging_type, params.ranging_role, params.auth_mode,\n+\t\t   params.freq, MAC2STR(params.peer_addr),\n+\t\t   MAC2STR(params.src_addr), params.pasn_role);\n+\n+\twpas_pr_pasn_trigger(wpa_s, &params);\n+\treturn 0;\n }\n \n \n@@ -11669,6 +11702,8 @@ fail:\n \treturn ret;\n }\n \n+\n+\n #endif /* CONFIG_PR */\n \n \n",
    "prefixes": [
        "RFC",
        "20/23"
    ]
}