From patchwork Mon Aug 27 10:38:07 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chun-Yeow Yeoh X-Patchwork-Id: 1377261 Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 0CBF53FC66 for ; Mon, 27 Aug 2012 10:39:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753305Ab2H0Kjx (ORCPT ); Mon, 27 Aug 2012 06:39:53 -0400 Received: from mail-pb0-f46.google.com ([209.85.160.46]:61163 "EHLO mail-pb0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753192Ab2H0Kjv (ORCPT ); Mon, 27 Aug 2012 06:39:51 -0400 Received: by pbbrr13 with SMTP id rr13so7209181pbb.19 for ; Mon, 27 Aug 2012 03:39:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer; bh=tv8jNXCq0mK9/y0rPSDG5DsAGZiEHpHQMJ5+LWBR//8=; b=jIQLU8Ggqh11oGBUP1kOQQJQn2d7z8DYAGDM/D07qJTD5+8GVooHRi4G6D49qgArQS kMx0zAgqxcgrDHNqSUvwyGT6S0dMGo/oVGxJ9jm4FQockDFBY3bNNu6ZEUcX3Kn4hBCK 7brvlXFEZqh8PBd8FPWK0fbMfv6Q4Hw5qQdXJSOkjNzXXo99NZbxaOsEt1NBJDpxtFVA 76XaHjan5iAmr3Z/53qFSv9hOq3yUWuMX3BrdqD1i0hTJmB+ZNk27bnyubT8sj/4hGA5 X+OpM/b+booElRGkmh2LL2W0mx3UF8uhVOLh0p+IAQf2Rv1GP8qK0e5qy8er5f0JaH0q llFw== Received: by 10.68.225.233 with SMTP id rn9mr33139401pbc.135.1346063991401; Mon, 27 Aug 2012 03:39:51 -0700 (PDT) Received: from localhost.localdomain ([58.26.233.146]) by mx.google.com with ESMTPS id sr4sm4361806pbc.24.2012.08.27.03.39.49 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 27 Aug 2012 03:39:50 -0700 (PDT) From: Chun-Yeow Yeoh To: linux-wireless@vger.kernel.org Cc: johannes@sipsolutions.net, Chun-Yeow Yeoh Subject: [PATCH] cfg80211: allow software encryption of aes cmac in mesh Date: Mon, 27 Aug 2012 18:38:07 +0800 Message-Id: <1346063887-29078-1-git-send-email-yeohchunyeow@gmail.com> X-Mailer: git-send-email 1.7.0.4 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Secured mesh requires the key installation using cipher suite AES CMAC for multicast management frame. This patch will allow the key installation to proceed. Otherwise, it will be rejected due to hw encryption is not supported. Signed-off-by: Chun-Yeow Yeoh --- net/wireless/util.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/net/wireless/util.c b/net/wireless/util.c index ef35f4e..1b665a7 100644 --- a/net/wireless/util.c +++ b/net/wireless/util.c @@ -253,7 +253,9 @@ int cfg80211_validate_key_settings(struct cfg80211_registered_device *rdev, } } - if (!cfg80211_supported_cipher_suite(&rdev->wiphy, params->cipher)) + if (!cfg80211_supported_cipher_suite(&rdev->wiphy, params->cipher) && + !(params->cipher == WLAN_CIPHER_SUITE_AES_CMAC && + (rdev->wiphy.flags & WIPHY_FLAG_MESH_AUTH))) return -EINVAL; return 0;