From patchwork Mon Sep 4 17:25:00 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Kamil Rytarowski X-Patchwork-Id: 9937481 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 12C6E601EB for ; Mon, 4 Sep 2017 17:38:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 025A8287B8 for ; Mon, 4 Sep 2017 17:38:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id EB0C7287E8; Mon, 4 Sep 2017 17:38:28 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 5B659287B8 for ; Mon, 4 Sep 2017 17:38:28 +0000 (UTC) Received: from localhost ([::1]:55041 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dovKN-0007uz-CW for patchwork-qemu-devel@patchwork.kernel.org; Mon, 04 Sep 2017 13:38:27 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44634) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dovJj-0007uV-2S for qemu-devel@nongnu.org; Mon, 04 Sep 2017 13:37:51 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dovJe-0002bq-HX for qemu-devel@nongnu.org; Mon, 04 Sep 2017 13:37:47 -0400 Received: from mout.gmx.net ([212.227.15.15]:61518) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dovJe-0002ap-2X for qemu-devel@nongnu.org; Mon, 04 Sep 2017 13:37:42 -0400 Received: from localhost.localdomain ([185.58.161.191]) by mail.gmx.com (mrgmx003 [212.227.17.184]) with ESMTPSA (Nemesis) id 0M8ehf-1dbwd80wrL-00wEa8; Mon, 04 Sep 2017 19:37:29 +0200 From: Kamil Rytarowski To: kraxel@redhat.com Date: Mon, 4 Sep 2017 19:25:00 +0200 Message-Id: <20170904172500.26513-1-n54@gmx.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20170903163455.15132-1-n54@gmx.com> References: <20170903163455.15132-1-n54@gmx.com> MIME-Version: 1.0 X-Provags-ID: V03:K0:4ZHHxRubZzGZRaJ02SsIwM1GQ6+qP9f+6iasL532FiaLjLgx4CX 2BmJZWZv516p6ngAwSXNAkf968grwyhvzlkiOZbKI2AzjVKlzaY+4gbEwQ4wvL8SolItxhL KFHBllDpdAg9uJc4A6tV9h3EMLjfOJYVRUh0KJTXoijDfbsbf7h9fBdsMneJzOOTW+8839u QFYDane10GtbbdmALzsgg== X-UI-Out-Filterresults: notjunk:1; V01:K0:dSkQEbRIOYw=:Df1mMpviYTZDVLHTUQnvj0 5S3lHBHOEs3J8KAX03g9vLF4nJu+s3+cQChVyCsD7cOR70XBZSQff9wfUb7CISQoQW1qw1Mg1 5LtbyX6neiM7sjtUnaIAI4MqNOB2upd8OT93i8VECiblJWVxX1LEeShmk73qm1fU7F04oLqeB fCF0/FhSMhqiYR3I9dicLA0e53+3gKH4BbwnXnZcP38g57TsiCecM1XnL/ZoYnDGSHVOSiIHJ TFHCMBlJSsFK4asRxSHh4MzsYknwcgvThbWvSFc77q4tpc1lvIUz3JUJNgTja3izwjSAPMsQZ /3jXnBnUIsGlnLt6dtsih5/oxeCLZI96PDzD7yPXgWu4NpPn9H/UR8aoL1hrfSjOxM1cwnnLZ EIzhP2otrlj4HdmNGim0Jp9DsyXz7JZ8Y/XT6o5XHhgbzUeUN+PrCWSh5WirxMy3Y5MzksLGi wPL4L0Xkfr6iBSXmx+oUrZao6VUoOg3yZ0tfdo9oA0zMSRlyzB2byuiEE/HbhnobUsIpxxM5K svMOGHYCw4QxUzfFSxkmkVQAIZYtb4lg15D9zR4LUlWSk5+lIi+Aacg8LpIi6sDBd3pRIyJMI xNK2K3aiIGWMrt5HasainJLXOSwnLiZBiZ6cpK5CY+ZtQlycrd1X4kOiUBO7q6tmrgQKW9VVd bRc10/oU4tnXWnoYtVZuq0msJs7QZtWT5LfMTgarH6u/BnXTZI6OhS73R4TqNEjX9+95VrKQ0 GyCuy1e+kdwX0BbD3Wps3STGdGAO545tD+vByfVVbL5zh/huoU+5rMwvqLfilcMnZRZ36L1wB gggmM6Lnw2LDRHRZckr9KO1nGpObgzvVQSo1LX1j159kOvyRAU= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 212.227.15.15 Subject: [Qemu-devel] [PATCH v2] usb-mtp: Add fallback definition of NAME_MAX X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Kamil Rytarowski , qemu-devel@nongnu.org, f4bug@amsat.org Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP This fixes build on SmartOS (Joyent). Patch cherry-picked from pkgsrc by jperkin (Joyent). Signed-off-by: Kamil Rytarowski Reviewed-by: Philippe Mathieu-Daudé --- include/qemu/osdep.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/qemu/osdep.h b/include/qemu/osdep.h index 6855b94bbf..5d3860f80e 100644 --- a/include/qemu/osdep.h +++ b/include/qemu/osdep.h @@ -306,6 +306,11 @@ void qemu_anon_ram_free(void *ptr, size_t size); #endif #endif +/* Required by SmartOS (SunOS) */ +#ifndef NAME_MAX +#define NAME_MAX 255 +#endif + #if defined(__linux__) && \ (defined(__x86_64__) || defined(__arm__) || defined(__aarch64__)) /* Use 2 MiB alignment so transparent hugepages can be used by KVM.