From patchwork Mon Aug 25 20:48:50 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mike Holmes X-Patchwork-Id: 35945 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vc0-f199.google.com (mail-vc0-f199.google.com [209.85.220.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id B20F4203C0 for ; Mon, 25 Aug 2014 20:49:12 +0000 (UTC) Received: by mail-vc0-f199.google.com with SMTP id la4sf42724351vcb.2 for ; Mon, 25 Aug 2014 13:49:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:date:message-id:subject :precedence:list-id:list-unsubscribe:list-archive:list-post :list-help:list-subscribe:mime-version:errors-to:sender :x-original-sender:x-original-authentication-results:mailing-list :content-type:content-transfer-encoding; bh=/inoghr1MuQyyjmhD1M3GZzeSr/tK7jqI4HylBRYtbw=; b=AVsRSQO3L1/a3/Gpey+ztnFeOvk3t0ryv46AOF3lkkqoacnI7h7QOfuLQUxUwgyODK EiLENifTNJ3sL3JZ+6FT+uAD8ZKxXCEgdr220ObkOjeQ/YUPqdzs7nYpWEDvthu4EzVc MW449BEezSAV6kiHfrG9Hpd/XcwyGnE9MzHo0mPnLvcO/5aQ3QoT3+Lxj7qJV8Ryc8OZ r9EXBY2tOePu2teiabr8pNc6iTSNSSphU1r2KR18Z4l3eHIeXAl/D/6YrkfOmoQI9am+ iza7ZDEdvqYX9UWQX8KJIfkgPR/BJQ+4i8x3tXhjCDwflIN0wW6ataYqt8fWlOEN3CDw akyw== X-Gm-Message-State: ALoCoQmiUGcSG9TbSp+nVIAyFMmRySligwZUKBPXKvtS5Jo0a2s1xEoTU16SdvBqWxfmAr9yuWa+ X-Received: by 10.236.199.108 with SMTP id w72mr2605812yhn.31.1408999752540; Mon, 25 Aug 2014 13:49:12 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.31.161 with SMTP id f30ls370355qgf.39.gmail; Mon, 25 Aug 2014 13:49:12 -0700 (PDT) X-Received: by 10.52.136.196 with SMTP id qc4mr7197271vdb.22.1408999752400; Mon, 25 Aug 2014 13:49:12 -0700 (PDT) Received: from mail-vc0-f174.google.com (mail-vc0-f174.google.com [209.85.220.174]) by mx.google.com with ESMTPS id qh2si557244vcb.81.2014.08.25.13.49.12 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 25 Aug 2014 13:49:12 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.174 as permitted sender) client-ip=209.85.220.174; Received: by mail-vc0-f174.google.com with SMTP id la4so15783099vcb.19 for ; Mon, 25 Aug 2014 13:49:12 -0700 (PDT) X-Received: by 10.220.74.10 with SMTP id s10mr3738885vcj.61.1408999752327; Mon, 25 Aug 2014 13:49:12 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.45.67 with SMTP id uj3csp146291vcb; Mon, 25 Aug 2014 13:49:11 -0700 (PDT) X-Received: by 10.224.37.134 with SMTP id x6mr39819080qad.39.1408999751727; Mon, 25 Aug 2014 13:49:11 -0700 (PDT) Received: from ip-10-141-164-156.ec2.internal (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTPS id 66si1386597qgz.26.2014.08.25.13.49.11 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Mon, 25 Aug 2014 13:49:11 -0700 (PDT) Received-SPF: none (google.com: lng-odp-bounces@lists.linaro.org does not designate permitted sender hosts) client-ip=54.225.227.206; Received: from localhost ([127.0.0.1] helo=ip-10-141-164-156.ec2.internal) by ip-10-141-164-156.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1XM1CP-0001mq-Si; Mon, 25 Aug 2014 20:49:09 +0000 Received: from mail-qc0-f179.google.com ([209.85.216.179]) by ip-10-141-164-156.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1XM1CK-0001mJ-FO for lng-odp@lists.linaro.org; Mon, 25 Aug 2014 20:49:04 +0000 Received: by mail-qc0-f179.google.com with SMTP id m20so14638541qcx.10 for ; Mon, 25 Aug 2014 13:48:59 -0700 (PDT) X-Received: by 10.224.128.9 with SMTP id i9mr39818929qas.50.1408999739270; Mon, 25 Aug 2014 13:48:59 -0700 (PDT) Received: from fedora1.holmesfamily.ws (c-98-221-136-245.hsd1.nj.comcast.net. [98.221.136.245]) by mx.google.com with ESMTPSA id k10sm2726974qaj.7.2014.08.25.13.48.58 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 25 Aug 2014 13:48:58 -0700 (PDT) From: Mike Holmes To: lng-odp@lists.linaro.org Date: Mon, 25 Aug 2014 16:48:50 -0400 Message-Id: <1408999731-35261-1-git-send-email-mike.holmes@linaro.org> X-Mailer: git-send-email 1.9.1 X-Topics: patch Subject: [lng-odp] [PATCH 1/2] linux-generic/odp_packet_socket.c: Add intalization X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Errors-To: lng-odp-bounces@lists.linaro.org Sender: lng-odp-bounces@lists.linaro.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: mike.holmes@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.174 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 Signed-off-by: Mike Holmes --- platform/linux-generic/odp_packet_socket.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/platform/linux-generic/odp_packet_socket.c b/platform/linux-generic/odp_packet_socket.c index d44c333..e7e82c1 100644 --- a/platform/linux-generic/odp_packet_socket.c +++ b/platform/linux-generic/odp_packet_socket.c @@ -255,6 +255,14 @@ int recv_pkt_sock_basic(pkt_sock_t *const pkt_sock, uint8_t *l2_hdr; int nb_rx = 0; + /* recvfrom: + * If the address argument is not a null pointer + * and the protocol does not provide the source address of + * messages, the the value stored in the object pointed to + * by address is unspecified. + */ + memset(&sll, 0, sizeof(sll)); + for (i = 0; i < len; i++) { if (odp_likely(pkt == ODP_PACKET_INVALID)) { pkt = odp_packet_alloc(pkt_sock->pool);