All of lore.kernel.org
 help / color / mirror / Atom feed
From: Adrian Bunk <bunk@fs.tum.de>
To: Andrew Morton <akpm@osdl.org>,
	Atul.Mukker@lsil.com, Sreenivas.Bagalkote@lsil.com,
	Manoj.Jose@lsil.com
Cc: linux-kernel@vger.kernel.org, James.Bottomley@SteelEye.com,
	linux-scsi@vger.kernel.org
Subject: [patch] 2.6.9-rc1-mm1: megaraid_mbox.c compile error with gcc 3.4
Date: Sat, 28 Aug 2004 11:06:51 +0200	[thread overview]
Message-ID: <20040828090651.GX12772@fs.tum.de> (raw)
In-Reply-To: <20040826014745.225d7a2c.akpm@osdl.org>

On Thu, Aug 26, 2004 at 01:47:45AM -0700, Andrew Morton wrote:
>...
> All patches:
>...
> bk-scsi.patch
>...

This results in many compile errors when using gcc 3.4 starting with the 
following:

<--  snip  -->

...
  CC      drivers/scsi/megaraid/megaraid_mbox.o
drivers/scsi/megaraid/megaraid_mbox.c: In function `megaraid_queue_command':
drivers/scsi/megaraid/megaraid_mbox.c:114: sorry, unimplemented: inlining failed
 in call to 'megaraid_mbox_build_cmd': function body not available
drivers/scsi/megaraid/megaraid_mbox.c:1410: sorry, unimplemented: called from here
drivers/scsi/megaraid/megaraid_mbox.c:123: sorry, unimplemented: inlining failed
 in call to 'megaraid_mbox_runpendq': function body not available
drivers/scsi/megaraid/megaraid_mbox.c:1413: sorry, unimplemented: called from here
make[3]: *** [drivers/scsi/megaraid/megaraid_mbox.o] Error 1

<--  snip  -->


The patch fixes this by removing the inline's from all functions where 
the inline function was called before it was defined.

An alterenate approach would be to reorder the file to move all inline'd 
functions above their first callers.


diffstat output:
 drivers/scsi/megaraid/megaraid_mbox.c |   44 +++++++++++++-------------
 1 files changed, 22 insertions(+), 22 deletions(-)



Signed-off-by: Adrian Bunk <bunk@fs.tum.de>

--- linux-2.6.9-rc1-mm1-full-3.4/drivers/scsi/megaraid/megaraid_mbox.c.old	2004-08-28 10:21:20.000000000 +0200
+++ linux-2.6.9-rc1-mm1-full-3.4/drivers/scsi/megaraid/megaraid_mbox.c	2004-08-28 10:31:23.000000000 +0200
@@ -110,26 +110,26 @@
 static int megaraid_queue_command(struct scsi_cmnd *,
 		void (*)(struct scsi_cmnd *));
 
-static inline scb_t *megaraid_mbox_build_cmd(adapter_t *, struct scsi_cmnd *,
+static scb_t *megaraid_mbox_build_cmd(adapter_t *, struct scsi_cmnd *,
 		int *);
-static inline scb_t *megaraid_alloc_scb(adapter_t *, struct scsi_cmnd *);
-static inline void megaraid_dealloc_scb(adapter_t *, scb_t *);
-static inline void megaraid_mbox_prepare_pthru(adapter_t *, scb_t *,
+static scb_t *megaraid_alloc_scb(adapter_t *, struct scsi_cmnd *);
+static void megaraid_dealloc_scb(adapter_t *, scb_t *);
+static void megaraid_mbox_prepare_pthru(adapter_t *, scb_t *,
 		struct scsi_cmnd *);
-static inline void megaraid_mbox_prepare_epthru(adapter_t *, scb_t *,
+static void megaraid_mbox_prepare_epthru(adapter_t *, scb_t *,
 		struct scsi_cmnd *);
-static inline int megaraid_mbox_mksgl(adapter_t *, scb_t *);
+static int megaraid_mbox_mksgl(adapter_t *, scb_t *);
 
-static inline void megaraid_mbox_runpendq(adapter_t *, scb_t *);
-static inline int mbox_post_cmd(adapter_t *, scb_t *);
+static void megaraid_mbox_runpendq(adapter_t *, scb_t *);
+static int mbox_post_cmd(adapter_t *, scb_t *);
 
 static void megaraid_mbox_dpc(unsigned long);
-static inline void megaraid_mbox_sync_scb(adapter_t *, scb_t *);
+static void megaraid_mbox_sync_scb(adapter_t *, scb_t *);
 
 static irqreturn_t megaraid_isr(int, void *, struct pt_regs *);
-static inline int megaraid_ack_sequence(adapter_t *);
+static int megaraid_ack_sequence(adapter_t *);
 
-static inline int megaraid_busywait_mbox(mraid_device_t *);
+static int megaraid_busywait_mbox(mraid_device_t *);
 
 static int megaraid_cmm_register(adapter_t *);
 static int megaraid_cmm_unregister(adapter_t *);
@@ -1434,7 +1434,7 @@
  * convert the command issued by mid-layer to format understood by megaraid
  * firmware. We also complete certain command without sending them to firmware
  */
-static inline scb_t *
+static scb_t *
 megaraid_mbox_build_cmd(adapter_t *adapter, struct scsi_cmnd *scp, int *busy)
 {
 	mraid_device_t		*rdev = ADAP2RAIDDEV(adapter);
@@ -1809,7 +1809,7 @@
  * return the scb from the head of the free list. NULL if there are none
  * available
  **/
-static inline scb_t *
+static scb_t *
 megaraid_alloc_scb(adapter_t *adapter, struct scsi_cmnd *scp)
 {
 	struct list_head	*head = &adapter->kscb_pool;
@@ -1847,7 +1847,7 @@
  * NOTE NOTE: Make sure the scb is not on any list before calling this
  * routine.
  **/
-static inline void
+static void
 megaraid_dealloc_scb(adapter_t *adapter, scb_t *scb)
 {
 	unsigned long		flags;
@@ -1873,7 +1873,7 @@
  *
  * prepare a command for the scsi physical devices
  */
-static inline void
+static void
 megaraid_mbox_prepare_pthru(adapter_t *adapter, scb_t *scb,
 		struct scsi_cmnd *scp)
 {
@@ -1921,7 +1921,7 @@
  * prepare a command for the scsi physical devices. This rountine prepares
  * commands for devices which can take extended CDBs (>10 bytes)
  */
-static inline void
+static void
 megaraid_mbox_prepare_epthru(adapter_t *adapter, scb_t *scb,
 		struct scsi_cmnd *scp)
 {
@@ -1967,7 +1967,7 @@
  *
  * prepare the scatter-gather list
  */
-static inline int
+static int
 megaraid_mbox_mksgl(adapter_t *adapter, scb_t *scb)
 {
 	struct scatterlist	*sgl;
@@ -2046,7 +2046,7 @@
  * out from the head of the pending list. If it is successfully issued, the
  * next SCB is at the head now.
  */
-static inline void
+static void
 megaraid_mbox_runpendq(adapter_t *adapter, scb_t *scb_q)
 {
 	scb_t			*scb;
@@ -2116,7 +2116,7 @@
  *
  * post the command to the controller if mailbox is availble.
  */
-static inline int
+static int
 mbox_post_cmd(adapter_t *adapter, scb_t *scb)
 {
 	mraid_device_t	*raid_dev = ADAP2RAIDDEV(adapter);
@@ -2218,7 +2218,7 @@
  *
  * Returns:	1 if the interrupt is valid, 0 otherwise
  */
-static inline int
+static int
 megaraid_ack_sequence(adapter_t *adapter)
 {
 	mraid_device_t		*raid_dev = ADAP2RAIDDEV(adapter);
@@ -2556,7 +2556,7 @@
  *
  * DMA sync if required.
  */
-static inline void
+static void
 megaraid_mbox_sync_scb(adapter_t *adapter, scb_t *scb)
 {
 	mbox_ccb_t	*ccb;
@@ -3069,7 +3069,7 @@
  * wait until the controller's mailbox is available to accept more commands.
  * wait for at most 1 second
  */
-static inline int
+static int
 megaraid_busywait_mbox(mraid_device_t *raid_dev)
 {
 	mbox_t	*mbox = raid_dev->mbox;


  parent reply	other threads:[~2004-08-28  9:06 UTC|newest]

Thread overview: 68+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-08-26  8:47 2.6.9-rc1-mm1 Andrew Morton
2004-08-26 11:07 ` 2.6.9-rc1-mm1 Con Kolivas
2004-08-26 14:28   ` 2.6.9-rc1-mm1 Jurriaan
2004-08-26 18:25     ` 2.6.9-rc1-mm1 Thomas Davis
2004-08-26 14:36   ` 2.6.9-rc1-mm1 Rafael J. Wysocki
2004-08-26 14:45     ` 2.6.9-rc1-mm1 Felipe Alfaro Solana
2004-08-26 15:35       ` 2.6.9-rc1-mm1 Rafael J. Wysocki
2004-08-26 16:38     ` 2.6.9-rc1-mm1 Con Kolivas
2004-08-26 20:36       ` 2.6.9-rc1-mm1 Rafael J. Wysocki
2004-08-26 20:55       ` 2.6.9-rc1-mm1 Martin J. Bligh
2004-08-26 23:19         ` 2.6.9-rc1-mm1 Con Kolivas
2004-08-26 23:43           ` 2.6.9-rc1-mm1 Martin J. Bligh
2004-08-27  0:37           ` 2.6.9-rc1-mm1 Nuno Silva
2004-08-27  0:46             ` 2.6.9-rc1-mm1 Con Kolivas
2004-08-27  0:51               ` 2.6.9-rc1-mm1 Martin J. Bligh
2004-08-27  0:55                 ` 2.6.9-rc1-mm1 Con Kolivas
2004-08-27  0:58         ` 2.6.9-rc1-mm1 Rick Lindsley
2004-08-27 20:54           ` 2.6.9-rc1-mm1 Rafael J. Wysocki
2004-08-27 21:54             ` 2.6.9-rc1-mm1 Rick Lindsley
2004-08-27 22:29               ` 2.6.9-rc1-mm1 Rafael J. Wysocki
2004-09-03 21:11               ` schedstat-2.6.8.1 [was: Re: 2.6.9-rc1-mm1] Rafael J. Wysocki
2004-09-08  7:09                 ` Rick Lindsley
2004-09-04 18:35               ` 2.6.9-rc1-mm1 Rafael J. Wysocki
2004-09-08  8:10                 ` 2.6.9-rc1-mm1 Rick Lindsley
2004-09-04 23:10               ` latency.c [was: Re: 2.6.9-rc1-mm1] Rafael J. Wysocki
2004-09-08  8:12                 ` Rick Lindsley
2004-09-08 12:02                   ` Rafael J. Wysocki
2004-08-26 20:51   ` 2.6.9-rc1-mm1 Martin J. Bligh
2004-08-27  1:43     ` 2.6.9-rc1-mm1 Nick Piggin
2004-08-26 12:06 ` 2.6.9-rc1-mm1 Denis Vlasenko
2004-08-26 19:40   ` 2.6.9-rc1-mm1 Sam Ravnborg
2004-08-26 17:58 ` 2.6.9-rc1-mm1 (compile stats) John Cherry
2004-08-26 18:53 ` 2.6.9-rc1-mm1 - undefined references - [PATCH] Paolo Ornati
2004-08-28  8:54   ` Adrian Bunk
2004-08-28  9:45     ` Paolo Ornati
2004-08-26 22:46 ` 2.6.9-rc1-mm1 Rafael J. Wysocki
2004-08-26 22:50   ` 2.6.9-rc1-mm1 Andrew Morton
2004-08-26 23:53 ` 2.6.9-rc1-mm1 Tomasz Torcz
     [not found] ` <20040827043132.GJ2793@holomorphy.com>
2004-08-27 21:42   ` 2.6.9-rc1-mm1 William Lee Irwin III
2004-08-28  5:26 ` [0/4] standardized waitqueue hashing William Lee Irwin III
2004-08-28  5:31   ` [1/4] standardize bit waiting data type William Lee Irwin III
2004-08-28  5:35     ` [2/4] consolidate bit waiting code patterns William Lee Irwin III
2004-08-28  5:37       ` [3/4] eliminate bh waitqueue hashtable William Lee Irwin III
2004-08-28  5:38         ` [4/4] eliminate inode " William Lee Irwin III
2004-08-28  6:17     ` [1/4] standardize bit waiting data type Andrew Morton
2004-08-28  6:34       ` William Lee Irwin III
2004-08-28  6:40         ` Andrew Morton
2004-08-28  6:48           ` William Lee Irwin III
2004-08-28  9:20             ` William Lee Irwin III
2004-08-28  9:22               ` [2/4] consolidate bit waiting code patterns William Lee Irwin III
2004-08-28  9:23                 ` [3/4] eliminate bh waitqueue hashtable William Lee Irwin III
2004-08-28  9:24                   ` [4/4] eliminate inode " William Lee Irwin III
2004-08-28  9:43                   ` [3/4] eliminate bh " Andrew Morton
2004-08-28  9:34                 ` [2/4] consolidate bit waiting code patterns Andrew Morton
2004-08-28  9:51                   ` William Lee Irwin III
2004-08-28  9:39                 ` Andrew Morton
2004-08-28  9:51                   ` William Lee Irwin III
2004-08-28  9:18     ` [1/4] standardize bit waiting data type Christoph Hellwig
2004-08-28  9:20       ` William Lee Irwin III
2004-08-28  9:06 ` Adrian Bunk [this message]
  -- strict thread matches above, loose matches on Subject: below --
2004-08-28 16:29 [patch] 2.6.9-rc1-mm1: megaraid_mbox.c compile error with gcc 3.4 Mukker, Atul
2004-08-28 20:04 ` Andrew Morton
2004-08-28 20:04   ` Andrew Morton
2004-08-28 20:17   ` Lee Revell
2004-08-29 13:34   ` James Bottomley
2004-08-31  6:49   ` Daniel Phillips
2004-08-30 13:05 Mukker, Atul
2004-08-30 19:55 ` Andrew Morton

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040828090651.GX12772@fs.tum.de \
    --to=bunk@fs.tum.de \
    --cc=Atul.Mukker@lsil.com \
    --cc=James.Bottomley@SteelEye.com \
    --cc=Manoj.Jose@lsil.com \
    --cc=Sreenivas.Bagalkote@lsil.com \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.