2009-01-28 05:02:52

by Kumar Gala

[permalink] [raw]
Subject: [PATCH] ahci: Fix build breakage

The following commit introduces:

commit 1fd684346d41f6be2487c161f60d03a7feb68911
Author: Rafael J. Wysocki <[email protected]>
Date: Mon Jan 19 20:57:36 2009 +0100

SATA AHCI: Blacklist system that spins off disks during ACPI power off

the following errors on non-x86 systems:

drivers/ata/ahci.c: In function 'ahci_broken_system_poweroff':
drivers/ata/ahci.c:2566: error: implicit declaration of function 'dmi_first_match'
drivers/ata/ahci.c:2566: warning: initialization makes pointer from integer without a cast

Signed-off-by: Kumar Gala <[email protected]>
---
drivers/ata/ahci.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c
index 77bba4c..2c84f53 100644
--- a/drivers/ata/ahci.c
+++ b/drivers/ata/ahci.c
@@ -2550,6 +2550,7 @@ static void ahci_p5wdh_workaround(struct ata_host *host)

static bool ahci_broken_system_poweroff(struct pci_dev *pdev)
{
+#ifdef CONFIG_DMI
static const struct dmi_system_id broken_systems[] = {
{
.ident = "HP Compaq nx6310",
@@ -2570,6 +2571,7 @@ static bool ahci_broken_system_poweroff(struct pci_dev *pdev)
/* apply the quirk only to on-board controllers */
return slot == PCI_SLOT(pdev->devfn);
}
+#endif

return false;
}
--
1.5.6.6


2009-01-28 05:03:15

by Kumar Gala

[permalink] [raw]
Subject: [PATCH] sata_sil: Fix build breakage

The following commit introduces:

commit e57db7bde7bff95ae812736ca00c73bd5271455b
Author: Rafael J. Wysocki <[email protected]>
Date: Mon Jan 19 20:58:29 2009 +0100

SATA Sil: Blacklist system that spins off disks during ACPI power off

the following build errors on non-x86 systems:

drivers/ata/sata_sil.c: In function 'sil_broken_system_poweroff':
drivers/ata/sata_sil.c:713: error: implicit declaration of function 'dmi_first_match'
drivers/ata/sata_sil.c:713: warning: initialization makes pointer from integer without a cast

Signed-off-by: Kumar Gala <[email protected]>
---
drivers/ata/sata_sil.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/ata/sata_sil.c b/drivers/ata/sata_sil.c
index bfd55b0..3f0549d 100644
--- a/drivers/ata/sata_sil.c
+++ b/drivers/ata/sata_sil.c
@@ -697,6 +697,7 @@ static void sil_init_controller(struct ata_host *host)

static bool sil_broken_system_poweroff(struct pci_dev *pdev)
{
+#ifdef CONFIG_DMI
static const struct dmi_system_id broken_systems[] = {
{
.ident = "HP Compaq nx6325",
@@ -717,6 +718,7 @@ static bool sil_broken_system_poweroff(struct pci_dev *pdev)
/* apply the quirk only to on-board controllers */
return slot == PCI_SLOT(pdev->devfn);
}
+#endif

return false;
}
--
1.5.6.6

2009-01-28 05:03:33

by Kumar Gala

[permalink] [raw]
Subject: [PATCH] ata_piix: Fix build breakage

The following commit introduces:

commit 5f451fe1ab5d73b987051f0d23c85216c552e163
Author: Rafael J. Wysocki <[email protected]>
Date: Mon Jan 19 20:59:22 2009 +0100

SATA PIIX: Blacklist system that spins off disks during ACPI power off

the following build errors on non-x86 systems:

drivers/ata/ata_piix.c: In function 'piix_broken_system_poweroff':
drivers/ata/ata_piix.c:1405: error: implicit declaration of function 'dmi_first_match'
drivers/ata/ata_piix.c:1405: warning: initialization makes pointer from integer without a cast

Signed-off-by: Kumar Gala <[email protected]>
---
drivers/ata/ata_piix.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/ata/ata_piix.c b/drivers/ata/ata_piix.c
index 54961c0..14874e1 100644
--- a/drivers/ata/ata_piix.c
+++ b/drivers/ata/ata_piix.c
@@ -1389,6 +1389,7 @@ static void piix_iocfg_bit18_quirk(struct ata_host *host)

static bool piix_broken_system_poweroff(struct pci_dev *pdev)
{
+#ifdef CONFIG_DMI
static const struct dmi_system_id broken_systems[] = {
{
.ident = "HP Compaq 2510p",
@@ -1409,6 +1410,7 @@ static bool piix_broken_system_poweroff(struct pci_dev *pdev)
/* apply the quirk only to on-board controllers */
return slot == PCI_SLOT(pdev->devfn);
}
+#endif

return false;
}
--
1.5.6.6

2009-01-28 06:08:51

by Kumar Gala

[permalink] [raw]
Subject: Re: [PATCH] ata_piix: Fix build breakage


On Jan 27, 2009, at 11:02 PM, Kumar Gala wrote:

> The following commit introduces:
>
> commit 5f451fe1ab5d73b987051f0d23c85216c552e163
> Author: Rafael J. Wysocki <[email protected]>
> Date: Mon Jan 19 20:59:22 2009 +0100
>
> SATA PIIX: Blacklist system that spins off disks during ACPI
> power off
>
> the following build errors on non-x86 systems:
>
> drivers/ata/ata_piix.c: In function 'piix_broken_system_poweroff':
> drivers/ata/ata_piix.c:1405: error: implicit declaration of function
> 'dmi_first_match'
> drivers/ata/ata_piix.c:1405: warning: initialization makes pointer
> from integer without a cast
>
> Signed-off-by: Kumar Gala <[email protected]>
> ---
> drivers/ata/ata_piix.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)

it was pointed out that fixing include/linux/dmi.h was the better way
to fix this. I've posted a patch for fixing dmi.h that supersedes
this patch.

- k

2009-01-28 06:14:20

by Kumar Gala

[permalink] [raw]
Subject: Re: [PATCH] sata_sil: Fix build breakage


On Jan 27, 2009, at 11:02 PM, Kumar Gala wrote:

> The following commit introduces:
>
> commit e57db7bde7bff95ae812736ca00c73bd5271455b
> Author: Rafael J. Wysocki <[email protected]>
> Date: Mon Jan 19 20:58:29 2009 +0100
>
> SATA Sil: Blacklist system that spins off disks during ACPI power
> off
>
> the following build errors on non-x86 systems:
>
> drivers/ata/sata_sil.c: In function 'sil_broken_system_poweroff':
> drivers/ata/sata_sil.c:713: error: implicit declaration of function
> 'dmi_first_match'
> drivers/ata/sata_sil.c:713: warning: initialization makes pointer
> from integer without a cast
>
> Signed-off-by: Kumar Gala <[email protected]>
> ---
> drivers/ata/sata_sil.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)


it was pointed out that fixing include/linux/dmi.h was the better way
to fix this. I've posted a patch for fixing dmi.h that supersedes
this patch.

- k

2009-01-28 06:43:17

by Kumar Gala

[permalink] [raw]
Subject: Re: [PATCH] ahci: Fix build breakage


On Jan 27, 2009, at 11:02 PM, Kumar Gala wrote:

> The following commit introduces:
>
> commit 1fd684346d41f6be2487c161f60d03a7feb68911
> Author: Rafael J. Wysocki <[email protected]>
> Date: Mon Jan 19 20:57:36 2009 +0100
>
> SATA AHCI: Blacklist system that spins off disks during ACPI
> power off
>
> the following errors on non-x86 systems:
>
> drivers/ata/ahci.c: In function 'ahci_broken_system_poweroff':
> drivers/ata/ahci.c:2566: error: implicit declaration of function
> 'dmi_first_match'
> drivers/ata/ahci.c:2566: warning: initialization makes pointer from
> integer without a cast
>
> Signed-off-by: Kumar Gala <[email protected]>
> ---
> drivers/ata/ahci.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)


it was pointed out that fixing include/linux/dmi.h was the better way
to fix this. I've posted a patch for fixing dmi.h that supersedes
this patch.

- k

2009-01-28 07:09:29

by Kumar Gala

[permalink] [raw]
Subject: Re: [PATCH] ata_piix: Fix build breakage


On Jan 27, 2009, at 11:02 PM, Kumar Gala wrote:

> The following commit introduces:
>
> commit 5f451fe1ab5d73b987051f0d23c85216c552e163
> Author: Rafael J. Wysocki <[email protected]>
> Date: Mon Jan 19 20:59:22 2009 +0100
>
> SATA PIIX: Blacklist system that spins off disks during ACPI
> power off
>
> the following build errors on non-x86 systems:
>
> drivers/ata/ata_piix.c: In function 'piix_broken_system_poweroff':
> drivers/ata/ata_piix.c:1405: error: implicit declaration of function
> 'dmi_first_match'
> drivers/ata/ata_piix.c:1405: warning: initialization makes pointer
> from integer without a cast
>
> Signed-off-by: Kumar Gala <[email protected]>
> ---
> drivers/ata/ata_piix.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)


it was pointed out that fixing include/linux/dmi.h was the better way
to fix this. I've posted a patch for fixing dmi.h that supersedes
this patch.

- k

2009-01-28 23:33:58

by Alexander Beregalov

[permalink] [raw]
Subject: Re: [PATCH] sata_sil: Fix build breakage

On Wed, Jan 28, 2009 at 12:08:56AM -0600, Kumar Gala wrote:
>
> On Jan 27, 2009, at 11:02 PM, Kumar Gala wrote:
>
>> The following commit introduces:
>>
>> commit e57db7bde7bff95ae812736ca00c73bd5271455b
>> Author: Rafael J. Wysocki <[email protected]>
>> Date: Mon Jan 19 20:58:29 2009 +0100
>>
>> SATA Sil: Blacklist system that spins off disks during ACPI power off
>>
>> the following build errors on non-x86 systems:
>>
>> drivers/ata/sata_sil.c: In function 'sil_broken_system_poweroff':
>> drivers/ata/sata_sil.c:713: error: implicit declaration of function
>> 'dmi_first_match'
>> drivers/ata/sata_sil.c:713: warning: initialization makes pointer from
>> integer without a cast
>>
>> Signed-off-by: Kumar Gala <[email protected]>
>> ---
>> drivers/ata/sata_sil.c | 2 ++
>> 1 files changed, 2 insertions(+), 0 deletions(-)
>
>
> it was pointed out that fixing include/linux/dmi.h was the better way to
> fix this. I've posted a patch for fixing dmi.h that supersedes this patch.
>

It breaks build for me in the same way even after your fix
(d8204ee2: dmi: Fix build breakage)

Subject: [PATCH] sata_sil: Fix build breakage
From: Alexander Beregalov <[email protected]>

Commit e57db7b (SATA Sil: Blacklist system that spins off disks during ACPI power off)
breaks build like the following, in both cases when CONFIG_DMI set or not.

drivers/ata/sata_sil.c: In function 'sil_broken_system_poweroff':
drivers/ata/sata_sil.c:713: error: implicit declaration of function 'dmi_first_match'
drivers/ata/sata_sil.c:713: warning: initialization makes pointer from integer without a cast

sata_sil.c should include dmi.h

Signed-off-by: Alexander Beregalov <[email protected]>
---


drivers/ata/sata_sil.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/ata/sata_sil.c b/drivers/ata/sata_sil.c
index bfd55b0..9f02959 100644
--- a/drivers/ata/sata_sil.c
+++ b/drivers/ata/sata_sil.c
@@ -44,6 +44,7 @@
#include <linux/device.h>
#include <scsi/scsi_host.h>
#include <linux/libata.h>
+#include <linux/dmi.h>

#define DRV_NAME "sata_sil"
#define DRV_VERSION "2.4"