From patchwork Tue Apr 13 14:32:47 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ben Widawsky X-Patchwork-Id: 12200749 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.7 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E15C6C433B4 for ; Tue, 13 Apr 2021 14:33:39 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id A7B4B6135C for ; Tue, 13 Apr 2021 14:33:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343770AbhDMOd6 (ORCPT ); Tue, 13 Apr 2021 10:33:58 -0400 Received: from mga06.intel.com ([134.134.136.31]:58955 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343824AbhDMOdh (ORCPT ); Tue, 13 Apr 2021 10:33:37 -0400 IronPort-SDR: ab/navwAl0RBZiGUZc7OwJn3pgVDRlHzzbmJV5WDgjAbQMLA3OPCkf+WO1yj2OIC1KES/K96Bv ON1y5Gi1OWcw== X-IronPort-AV: E=McAfee;i="6200,9189,9953"; a="255744581" X-IronPort-AV: E=Sophos;i="5.82,219,1613462400"; d="scan'208";a="255744581" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Apr 2021 07:32:53 -0700 IronPort-SDR: qxIHVA/iFiSeIjcOBRUEdggu0+r9rrF9/zHBHjMBmB8UWTYELRxZ2+Ob4rnbvhVtWm0uzuJvVQ Xbwst7Wd8HAQ== X-IronPort-AV: E=Sophos;i="5.82,219,1613462400"; d="scan'208";a="420811972" Received: from damilitx-mobl1.amr.corp.intel.com (HELO bwidawsk-mobl5.local) ([10.252.134.165]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 13 Apr 2021 07:32:53 -0700 From: Ben Widawsky To: linux-cxl@vger.kernel.org Cc: Ben Widawsky , linux-pci@vger.kernel.org, linux-acpi@vger.kernel.org, ira.weiny@intel.com, vishal.l.verma@intel.com, alison.schofield@intel.com, dan.j.williams@intel.com, linux-kernel@vger.kernel.org Subject: [PATCH] cxl/mem: Clarify UAPI documentation Date: Tue, 13 Apr 2021 07:32:47 -0700 Message-Id: <20210413143247.546256-1-ben.widawsky@intel.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org Signed-off-by: Ben Widawsky Acked-by: Jonathan Cameron --- include/uapi/linux/cxl_mem.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/uapi/linux/cxl_mem.h b/include/uapi/linux/cxl_mem.h index f6e8a005b113..8dd516ddb098 100644 --- a/include/uapi/linux/cxl_mem.h +++ b/include/uapi/linux/cxl_mem.h @@ -81,6 +81,13 @@ static const struct { * - @size_in = -1 * - @size_out = 0 * + * Commands which have a variable length input likely have a minimum length. + * This is not enforced by the UAPI, and therefore might look like the command + * succeeded when sending too small of an input payload. Caution should be taken + * by checking the @cxl_send_command.retval for such cases. For commands with a + * variable length output, the caller is free to consume as little or as much as + * they want. + * * See struct cxl_mem_query_commands. */ struct cxl_command_info {