From patchwork Mon Dec 6 16:19:48 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Beulich X-Patchwork-Id: 378702 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id oB6GJsDv027651 for ; Mon, 6 Dec 2010 16:19:55 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752015Ab0LFQTy (ORCPT ); Mon, 6 Dec 2010 11:19:54 -0500 Received: from vpn.id2.novell.com ([195.33.99.129]:49177 "EHLO vpn.id2.novell.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751744Ab0LFQTx convert rfc822-to-8bit (ORCPT ); Mon, 6 Dec 2010 11:19:53 -0500 Received: from EMEA1-MTA by vpn.id2.novell.com with Novell_GroupWise; Mon, 06 Dec 2010 16:49:38 +0000 Message-Id: <4CFD1B34020000780002625B@vpn.id2.novell.com> X-Mailer: Novell GroupWise Internet Agent 8.0.1 Date: Mon, 06 Dec 2010 16:19:48 +0000 From: "Jan Beulich" To: Subject: [PATCH] allow exception table to be put in .rodata Mime-Version: 1.0 Content-Disposition: inline Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Mon, 06 Dec 2010 16:19:55 +0000 (UTC) --- linux-2.6.37-rc4/arch/x86/kernel/vmlinux.lds.S +++ 2.6.37-rc4-extable-in-rodata/arch/x86/kernel/vmlinux.lds.S @@ -20,6 +20,8 @@ #define LOAD_OFFSET __START_KERNEL_map #endif +#define EXCEPTION_TABLE_RO EXCEPTION_TABLE(16) + #include #include #include @@ -113,8 +115,7 @@ SECTIONS } :text = 0x9090 NOTES :text :note - - EXCEPTION_TABLE(16) :text = 0x9090 + text_continues : {} :text /* switch back to regular text... */ X64_ALIGN_DEBUG_RODATA_BEGIN RO_DATA(PAGE_SIZE) --- linux-2.6.37-rc4/include/asm-generic/vmlinux.lds.h +++ 2.6.37-rc4-extable-in-rodata/include/asm-generic/vmlinux.lds.h @@ -219,6 +219,7 @@ *(.rodata1) \ } \ \ + EXCEPTION_TABLE_RO \ BUG_TABLE \ \ JUMP_TABLE \ @@ -439,6 +440,10 @@ VMLINUX_SYMBOL(__stop___ex_table) = .; \ } +#ifndef EXCEPTION_TABLE_RO +#define EXCEPTION_TABLE_RO +#endif + /* * Init task */