From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753584AbbC3UF6 (ORCPT ); Mon, 30 Mar 2015 16:05:58 -0400 Received: from smtprelay0150.hostedemail.com ([216.40.44.150]:49723 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753041AbbC3UF4 (ORCPT ); Mon, 30 Mar 2015 16:05:56 -0400 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::::,RULES_HIT:41:355:379:541:599:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1541:1593:1594:1711:1730:1747:1777:1792:2198:2199:2393:2559:2562:2828:3138:3139:3140:3141:3142:3352:3622:3865:3866:3867:3868:3871:3872:4031:4250:4321:5007:6117:6261:7875:8603:10004:10400:10848:11026:11232:11473:11658:11914:12043:12438:12517:12519:12555:12663:12740:13069:13311:13357:21080,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0 X-HE-Tag: idea93_8ad19b7819e4b X-Filterd-Recvd-Size: 1940 Message-ID: <1427745952.14276.24.camel@perches.com> Subject: Re: [PATCH -next] mac80211: Use #define IEEE80211_CCMP_PN_LEN and bool From: Joe Perches To: Johannes Berg Cc: "David S. Miller" , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Date: Mon, 30 Mar 2015 13:05:52 -0700 In-Reply-To: <1427745718.26117.46.camel@sipsolutions.net> References: <1427733474.14276.11.camel@perches.com> <1427745718.26117.46.camel@sipsolutions.net> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.12.10-0ubuntu1~14.10.1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2015-03-30 at 22:01 +0200, Johannes Berg wrote: > On Mon, 2015-03-30 at 09:37 -0700, Joe Perches wrote: > > > @@ -89,11 +90,11 @@ struct ieee80211_fragment_entry { > > unsigned int last_frag; > > unsigned int extra_len; > > struct sk_buff_head skb_list; > > - int ccmp; /* Whether fragments were encrypted with CCMP */ > > - u8 last_pn[6]; /* PN of the last fragment if CCMP was used */ > > + /* for CCMP fragments */ > > + bool ccmp; /* encrypted with CCMP */ > > + u8 last_pn[IEEE80211_CCMP_PN_LEN]; /* PN of the last fragment */ > > I took your patch as an opportunity to check into this, and it turns out > all of this logic is also going to be needed for GCMP. As a result, I'm > not going to take this patch but instead we'll fix it up for GCMP (where > using CCMP_PN_LEN would not be appropriate anyway - perhaps we need a > union or just keep '8' which is the right size for both anyway, or we'll > go to a u64 value or something) No worries. Whatever's right.