From patchwork Tue Nov 27 19:23:08 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gustavo Zacarias X-Patchwork-Id: 202285 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ozlabs.org (Postfix) with ESMTP id 286B52C007A for ; Wed, 28 Nov 2012 06:23:28 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 527A488404; Tue, 27 Nov 2012 19:23:24 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id s0lvQQz2fpwS; Tue, 27 Nov 2012 19:23:22 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 97AEA81494; Tue, 27 Nov 2012 19:23:21 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 4B5A58F74A for ; Tue, 27 Nov 2012 19:23:25 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 6129D81494 for ; Tue, 27 Nov 2012 19:23:20 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ysGMHBCdbIJD for ; Tue, 27 Nov 2012 19:23:19 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from loknar.toptech.com.ar (loknar.toptech.com.ar [78.46.79.162]) by whitealder.osuosl.org (Postfix) with ESMTPS id 9E8E880116 for ; Tue, 27 Nov 2012 19:23:18 +0000 (UTC) Received: from asgard (host201.201-252-64.telecom.net.ar [201.252.64.201]) (authenticated bits=0) by loknar.toptech.com.ar (8.14.5/8.14.5) with ESMTP id qARJNATe020491 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 27 Nov 2012 19:23:13 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=zacarias.com.ar; s=dkey; t=1354044195; bh=MaEtyW3rXGEByZGZQQSfcAaa5MhfF/H6DM91BlGnk/I=; h=From:To:Cc:Subject:Date; b=XOMi0tK8yscK/u4P8YrylNpSDDT/2jQITYaRXquvvgdD1Zh5Uto3XxwMB4mNrQLAF 6BhQ8COzNkSRjur/IZWSGVvvIoUSTxtDKgL986wxBTwwaiKDTbPbceE6jV/I/zF6CF PDYxWb4v/g60dJ4lcCMmyYOySTMH1McxEHwsWnfk= Received: by asgard (sSMTP sendmail emulation); Tue, 27 Nov 2012 16:23:08 -0300 From: Gustavo Zacarias To: buildroot@busybox.net Date: Tue, 27 Nov 2012 16:23:08 -0300 Message-Id: <1354044188-23646-1-git-send-email-gustavo@zacarias.com.ar> X-Mailer: git-send-email 1.7.8.6 X-Virus-Scanned: clamav-milter 0.97.5 at loknar X-Virus-Status: Clean Subject: [Buildroot] [PATCH] ocf-linux: tweak kernel patch for newer kernels X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net Newer kernels had a slight change in the random number API so the OCF patchset requires a slight tweak to build and run properly. Affected kernels are, per series: >=3.0.41, >=3.2.29, >=3.4.9, >=3.5.2 and any newer version. The fix is applied by detecting the API change rather than guessing the kernel version. Signed-off-by: Gustavo Zacarias --- linux/linux-ext-ocf-linux.mk | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/linux/linux-ext-ocf-linux.mk b/linux/linux-ext-ocf-linux.mk index faf7360..1a601d5 100644 --- a/linux/linux-ext-ocf-linux.mk +++ b/linux/linux-ext-ocf-linux.mk @@ -15,6 +15,8 @@ LINUX_DEPENDENCIES += ocf-linux define OCF_LINUX_PREPARE_KERNEL support/scripts/apply-patches.sh $(LINUX_DIR) \ $(OCF_LINUX_DIR)/patches/ linux-3.2.1-ocf.patch ; \ + grep -q __mix_pool_bytes $(LINUX_DIR)/drivers/char/random.c && \ + $(SED) 's:wordcount\*4:&, NULL:' $(LINUX_DIR)/drivers/char/random.c ; \ cp -rf $(OCF_LINUX_DIR)/ocf $(LINUX_DIR)/crypto/ocf ; endef