From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by befuddled.reisers.ca (Postfix, from userid 65534) id EB62E1EF6B4; Thu, 18 Jul 2013 02:55:56 -0400 (EDT) Received: from aserp1040.oracle.com (aserp1040.oracle.com [141.146.126.69]) by befuddled.reisers.ca (Postfix) with ESMTPS id 3F64C1EF56F for ; Thu, 18 Jul 2013 02:55:56 -0400 (EDT) Received: from ucsinet22.oracle.com (ucsinet22.oracle.com [156.151.31.94]) by aserp1040.oracle.com (Sentrion-MTA-4.3.1/Sentrion-MTA-4.3.1) with ESMTP id r6I6tsYt013955 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Thu, 18 Jul 2013 06:55:55 GMT Received: from aserz7021.oracle.com (aserz7021.oracle.com [141.146.126.230]) by ucsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r6I6trEW015393 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Thu, 18 Jul 2013 06:55:53 GMT Received: from abhmt118.oracle.com (abhmt118.oracle.com [141.146.116.70]) by aserz7021.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r6I6trHk002445 for ; Thu, 18 Jul 2013 06:55:53 GMT MIME-Version: 1.0 Message-ID: <0d30e6e5-261e-47e0-b5da-2ce5fe6bad24@default> Date: Wed, 17 Jul 2013 23:55:50 -0700 (PDT) From: Don Raikes Sender: Don Raikes To: "Speakup is a screen review system for Linux." Subject: OT: kernel oops X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.7 (607090) [OL 12.0.6668.5000 (x86)] X-Source-IP: ucsinet22.oracle.com [156.151.31.94] X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.2 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.15 X-BeenThere: speakup@linux-speakup.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: "Speakup is a screen review system for Linux." List-Id: "Speakup is a screen review system for Linux." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Jul 2013 06:55:57 -0000 Hi again, =20 After browsing some of both Linux Device Drivers and Linux Kernel Developme= nt, I modified my kernel module code and now I get a kernel oops. =20 I am trying to hook the sys_write() system call based on some code from my = professor. =20 The section of code that is having problems looks like this: =20 Char *tbuf =3D NULL; tbuf =3D kmalloc(count, GFP_ATOMIC); // count is passed in from userspace if (!tbuf) return -ENOMEM; if (copy_from_user(&tbuf, buf, count)) return -EFAULT; printk(KERN_INFO "Copy_from_user succeeded."\n"); kfree(tbuf); =20 I get a segmentation fault immediately after it prints copy_from_user succe= eded into the log. =20 Oops message: Oops: 0000 [#9] SMP =20 And as far as I can tell it is pointing to the kfree function at offset 0xb= a of 0xc0. =20 If there is a better place to post this (say a Linux developers list), I am= happy to take my questions there, but this list is my first port of call f= or errors with Linux. --=20 Best Regards, Donald HYPERLINK "http://www.oracle.com/" \nOracle Donald raikes | Accessibility Specialist/ QA Engineer Phone: HYPERLINK "tel:+15202717608"+15202717608 | Mobile: HYPERLINK "tel:+1= 5202717608"+15202717608=20 Oracle Quality Assurance | Tucson, Arizona=20 HYPERLINK "http://www.oracle.com/commitment" \nGreen Oracle Oracle is committed to developing practices and products that help protect = the environment =20