From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jody Bruchon Subject: [PATCH] Fix meta.c compile error Date: Sat, 11 Feb 2012 01:39:01 -0500 Message-ID: <4F360D05.5090602@jodybruchon.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------070902020003040105000204" Return-path: Sender: linux-8086-owner@vger.kernel.org List-ID: To: linux-8086@vger.kernel.org This is a multi-part message in MIME format. --------------070902020003040105000204 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit commit a29edafa1d8aaded59d5dd1037f937dbfd79095d Author: Jody Bruchon Date: Sat Feb 11 01:31:13 2012 -0500 In arch/i86/drivers/char/meta.c, a struct declaration issued a function call with a variable whose declaration was placed after the struct declaration, causing a compile error. I have moved the variable's declaration to be performed first, fixing the compile error. Signed-off-by: Jody Bruchon Committed-by: Jody Bruchon --------------070902020003040105000204 Content-Type: text/plain; name="0001-fix_meta_compile_error.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0001-fix_meta_compile_error.patch" diff --git a/elks/arch/i86/drivers/char/meta.c b/elks/arch/i86/drivers/char/meta.c index 2535aa9..5fed196 100644 --- a/elks/arch/i86/drivers/char/meta.c +++ b/elks/arch/i86/drivers/char/meta.c @@ -67,11 +67,11 @@ int post_request(struct ud_driver *driver, struct ud_request *request) static void do_meta_request(kdev_t device) { + int major = MAJOR(device); struct ud_driver *driver = get_driver(major); struct ud_request *udr; struct request *req; char *buff; - int major = MAJOR(device); printk("do_meta_request %d %x\n", major, blk_dev[major].current_request); if (NULL == driver) { --------------070902020003040105000204--