diff mbox

ARM: socfpga: fix build error due to secondary_startup

Message ID 1448902977-26176-1-git-send-email-dinguyen@opensource.altera.com (mailing list archive)
State New, archived
Headers show

Commit Message

dinguyen@opensource.altera.com Nov. 30, 2015, 5:02 p.m. UTC
From: Kevin Hilman <khilman@linaro.org>

After commit 02b4e2756e01 (ARM: v7 setup function should invalidate L1
cache) the soc specific secondary_startup is removed, causing build
failures:

../arch/arm/mach-socfpga/platsmp.c: In function 'socfpga_a10_boot_secondary':
../arch/arm/mach-socfpga/platsmp.c:66:140: error: 'socfpga_secondary_startup' undeclared (first use in this function)
../arch/arm/mach-socfpga/platsmp.c:66:140: note: each undeclared identifier is reported only once for each function it appears in

To fix, use the generic secondary_startup.

Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
Signed-off-by: Kevin Hilman <khilman@linaro.org>
---
Hi Greg,

Please consider applying this patch for fix a build error for SoCFPGA on
4.1.13-ltsi-rc1

Thanks,
Dinh
---
 arch/arm/mach-socfpga/platsmp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Greg Kroah-Hartman Dec. 4, 2015, 4:12 p.m. UTC | #1
On Mon, Nov 30, 2015 at 11:15:33AM -0600, Dinh Nguyen wrote:
> On 11/30/2015 11:20 AM, Greg KH wrote:
> > On Mon, Nov 30, 2015 at 11:02:57AM -0600, dinguyen@opensource.altera.com wrote:
> >> From: Kevin Hilman <khilman@linaro.org>
> >>
> >> After commit 02b4e2756e01 (ARM: v7 setup function should invalidate L1
> >> cache) the soc specific secondary_startup is removed, causing build
> >> failures:
> >>
> >> ../arch/arm/mach-socfpga/platsmp.c: In function 'socfpga_a10_boot_secondary':
> >> ../arch/arm/mach-socfpga/platsmp.c:66:140: error: 'socfpga_secondary_startup' undeclared (first use in this function)
> >> ../arch/arm/mach-socfpga/platsmp.c:66:140: note: each undeclared identifier is reported only once for each function it appears in
> >>
> >> To fix, use the generic secondary_startup.
> >>
> >> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
> >> Signed-off-by: Kevin Hilman <khilman@linaro.org>
> >> ---
> >> Hi Greg,
> >>
> >> Please consider applying this patch for fix a build error for SoCFPGA on
> >> 4.1.13-ltsi-rc1
> > 
> > Is this patch upstream?  If so, what is the git commit id?
> > 
> 
> Yes, sorry about that. The commit id is:
> 
> commit 89b8da06ba302dd130df60df7964ccd3ab151cd6

Thanks.  But why is this patch needed?  commit 02b4e2756e01 showed up in
4.2-rc1, it's not in the 4.1 tree, and as such, isn't in the 4.1-ltsi
tree either, so I don't understand why this patch should be applied.

confused,

greg k-h
dinguyen@opensource.altera.com Dec. 4, 2015, 4:34 p.m. UTC | #2
On Fri, 4 Dec 2015, Greg KH wrote:

> On Mon, Nov 30, 2015 at 11:15:33AM -0600, Dinh Nguyen wrote:
> > On 11/30/2015 11:20 AM, Greg KH wrote:
> > > On Mon, Nov 30, 2015 at 11:02:57AM -0600, dinguyen@opensource.altera.com wrote:
> > >> From: Kevin Hilman <khilman@linaro.org>
> > >>
> > >> After commit 02b4e2756e01 (ARM: v7 setup function should invalidate L1
> > >> cache) the soc specific secondary_startup is removed, causing build
> > >> failures:
> > >>
> > >> ../arch/arm/mach-socfpga/platsmp.c: In function 'socfpga_a10_boot_secondary':
> > >> ../arch/arm/mach-socfpga/platsmp.c:66:140: error: 'socfpga_secondary_startup' undeclared (first use in this function)
> > >> ../arch/arm/mach-socfpga/platsmp.c:66:140: note: each undeclared identifier is reported only once for each function it appears in
> > >>
> > >> To fix, use the generic secondary_startup.
> > >>
> > >> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
> > >> Signed-off-by: Kevin Hilman <khilman@linaro.org>
> > >> ---
> > >> Hi Greg,
> > >>
> > >> Please consider applying this patch for fix a build error for SoCFPGA on
> > >> 4.1.13-ltsi-rc1
> > > 
> > > Is this patch upstream?  If so, what is the git commit id?
> > > 
> > 
> > Yes, sorry about that. The commit id is:
> > 
> > commit 89b8da06ba302dd130df60df7964ccd3ab151cd6
> 
> Thanks.  But why is this patch needed?  commit 02b4e2756e01 showed up in
> 4.2-rc1, it's not in the 4.1 tree, and as such, isn't in the 4.1-ltsi
> tree either, so I don't understand why this patch should be applied.
>

I see the 02b4e2756e01 commit as this in the v4.1.13 branch:

commit a3595b864a2d64cf5084cbd822be622a4b0f5664
Author: Russell King <rmk+kernel@arm.linux.org.uk>
Date:   Tue May 19 17:06:44 2015 +0100

    ARM: v7 setup function should invalidate L1 cache

    commit 02b4e2756e01c623cc4dbceae4b07be75252db5b upstream. 

Thanks,

Dinh
Greg Kroah-Hartman Dec. 4, 2015, 5:19 p.m. UTC | #3
On Fri, Dec 04, 2015 at 10:34:22AM -0600, Dinh Nguyen wrote:
> On Fri, 4 Dec 2015, Greg KH wrote:
> 
> > On Mon, Nov 30, 2015 at 11:15:33AM -0600, Dinh Nguyen wrote:
> > > On 11/30/2015 11:20 AM, Greg KH wrote:
> > > > On Mon, Nov 30, 2015 at 11:02:57AM -0600, dinguyen@opensource.altera.com wrote:
> > > >> From: Kevin Hilman <khilman@linaro.org>
> > > >>
> > > >> After commit 02b4e2756e01 (ARM: v7 setup function should invalidate L1
> > > >> cache) the soc specific secondary_startup is removed, causing build
> > > >> failures:
> > > >>
> > > >> ../arch/arm/mach-socfpga/platsmp.c: In function 'socfpga_a10_boot_secondary':
> > > >> ../arch/arm/mach-socfpga/platsmp.c:66:140: error: 'socfpga_secondary_startup' undeclared (first use in this function)
> > > >> ../arch/arm/mach-socfpga/platsmp.c:66:140: note: each undeclared identifier is reported only once for each function it appears in
> > > >>
> > > >> To fix, use the generic secondary_startup.
> > > >>
> > > >> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
> > > >> Signed-off-by: Kevin Hilman <khilman@linaro.org>
> > > >> ---
> > > >> Hi Greg,
> > > >>
> > > >> Please consider applying this patch for fix a build error for SoCFPGA on
> > > >> 4.1.13-ltsi-rc1
> > > > 
> > > > Is this patch upstream?  If so, what is the git commit id?
> > > > 
> > > 
> > > Yes, sorry about that. The commit id is:
> > > 
> > > commit 89b8da06ba302dd130df60df7964ccd3ab151cd6
> > 
> > Thanks.  But why is this patch needed?  commit 02b4e2756e01 showed up in
> > 4.2-rc1, it's not in the 4.1 tree, and as such, isn't in the 4.1-ltsi
> > tree either, so I don't understand why this patch should be applied.
> >
> 
> I see the 02b4e2756e01 commit as this in the v4.1.13 branch:
> 
> commit a3595b864a2d64cf5084cbd822be622a4b0f5664
> Author: Russell King <rmk+kernel@arm.linux.org.uk>
> Date:   Tue May 19 17:06:44 2015 +0100
> 
>     ARM: v7 setup function should invalidate L1 cache
> 
>     commit 02b4e2756e01c623cc4dbceae4b07be75252db5b upstream. 

Ah, then why didn't you send this to the stable@vger.kernel.org mailing
list so that it can be included upstream so that everyone can benifit
from the fix, not just the ltsi kernel release?

Please do that, we never want to have patches in our tree that should be
in the stable releases instead, that's just rude to the rest of the
kernel community that you are basing your work on.

thanks,

greg k-h
dinguyen@opensource.altera.com Dec. 4, 2015, 5:20 p.m. UTC | #4
On Fri, 4 Dec 2015, Greg KH wrote:

> On Fri, Dec 04, 2015 at 10:34:22AM -0600, Dinh Nguyen wrote:
> > On Fri, 4 Dec 2015, Greg KH wrote:
> > 
> > > On Mon, Nov 30, 2015 at 11:15:33AM -0600, Dinh Nguyen wrote:
> > > > On 11/30/2015 11:20 AM, Greg KH wrote:
> > > > > On Mon, Nov 30, 2015 at 11:02:57AM -0600, dinguyen@opensource.altera.com wrote:
> > > > >> From: Kevin Hilman <khilman@linaro.org>
> > > > >>
> > > > >> After commit 02b4e2756e01 (ARM: v7 setup function should invalidate L1
> > > > >> cache) the soc specific secondary_startup is removed, causing build
> > > > >> failures:
> > > > >>
> > > > >> ../arch/arm/mach-socfpga/platsmp.c: In function 'socfpga_a10_boot_secondary':
> > > > >> ../arch/arm/mach-socfpga/platsmp.c:66:140: error: 'socfpga_secondary_startup' undeclared (first use in this function)
> > > > >> ../arch/arm/mach-socfpga/platsmp.c:66:140: note: each undeclared identifier is reported only once for each function it appears in
> > > > >>
> > > > >> To fix, use the generic secondary_startup.
> > > > >>
> > > > >> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
> > > > >> Signed-off-by: Kevin Hilman <khilman@linaro.org>
> > > > >> ---
> > > > >> Hi Greg,
> > > > >>
> > > > >> Please consider applying this patch for fix a build error for SoCFPGA on
> > > > >> 4.1.13-ltsi-rc1
> > > > > 
> > > > > Is this patch upstream?  If so, what is the git commit id?
> > > > > 
> > > > 
> > > > Yes, sorry about that. The commit id is:
> > > > 
> > > > commit 89b8da06ba302dd130df60df7964ccd3ab151cd6
> > > 
> > > Thanks.  But why is this patch needed?  commit 02b4e2756e01 showed up in
> > > 4.2-rc1, it's not in the 4.1 tree, and as such, isn't in the 4.1-ltsi
> > > tree either, so I don't understand why this patch should be applied.
> > >
> > 
> > I see the 02b4e2756e01 commit as this in the v4.1.13 branch:
> > 
> > commit a3595b864a2d64cf5084cbd822be622a4b0f5664
> > Author: Russell King <rmk+kernel@arm.linux.org.uk>
> > Date:   Tue May 19 17:06:44 2015 +0100
> > 
> >     ARM: v7 setup function should invalidate L1 cache
> > 
> >     commit 02b4e2756e01c623cc4dbceae4b07be75252db5b upstream. 
> 
> Ah, then why didn't you send this to the stable@vger.kernel.org mailing
> list so that it can be included upstream so that everyone can benifit
> from the fix, not just the ltsi kernel release?
> 
> Please do that, we never want to have patches in our tree that should be
> in the stable releases instead, that's just rude to the rest of the
> kernel community that you are basing your work on.
> 

Sorry about that. Will do that now.

Thanks,
Dinh
dinguyen@opensource.altera.com Dec. 10, 2015, 9:01 p.m. UTC | #5
On 12/04/2015 11:19 AM, Greg KH wrote:
> On Fri, Dec 04, 2015 at 10:34:22AM -0600, Dinh Nguyen wrote:
>> On Fri, 4 Dec 2015, Greg KH wrote:
>>
>>> On Mon, Nov 30, 2015 at 11:15:33AM -0600, Dinh Nguyen wrote:
>>>> On 11/30/2015 11:20 AM, Greg KH wrote:
>>>>> On Mon, Nov 30, 2015 at 11:02:57AM -0600, dinguyen@opensource.altera.com wrote:
>>>>>> From: Kevin Hilman <khilman@linaro.org>
>>>>>>
>>>>>> After commit 02b4e2756e01 (ARM: v7 setup function should invalidate L1
>>>>>> cache) the soc specific secondary_startup is removed, causing build
>>>>>> failures:
>>>>>>
>>>>>> ../arch/arm/mach-socfpga/platsmp.c: In function 'socfpga_a10_boot_secondary':
>>>>>> ../arch/arm/mach-socfpga/platsmp.c:66:140: error: 'socfpga_secondary_startup' undeclared (first use in this function)
>>>>>> ../arch/arm/mach-socfpga/platsmp.c:66:140: note: each undeclared identifier is reported only once for each function it appears in
>>>>>>
>>>>>> To fix, use the generic secondary_startup.
>>>>>>
>>>>>> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
>>>>>> Signed-off-by: Kevin Hilman <khilman@linaro.org>
>>>>>> ---
>>>>>> Hi Greg,
>>>>>>
>>>>>> Please consider applying this patch for fix a build error for SoCFPGA on
>>>>>> 4.1.13-ltsi-rc1
>>>>>
>>>>> Is this patch upstream?  If so, what is the git commit id?
>>>>>
>>>>
>>>> Yes, sorry about that. The commit id is:
>>>>
>>>> commit 89b8da06ba302dd130df60df7964ccd3ab151cd6
>>>
>>> Thanks.  But why is this patch needed?  commit 02b4e2756e01 showed up in
>>> 4.2-rc1, it's not in the 4.1 tree, and as such, isn't in the 4.1-ltsi
>>> tree either, so I don't understand why this patch should be applied.
>>>
>>
>> I see the 02b4e2756e01 commit as this in the v4.1.13 branch:
>>
>> commit a3595b864a2d64cf5084cbd822be622a4b0f5664
>> Author: Russell King <rmk+kernel@arm.linux.org.uk>
>> Date:   Tue May 19 17:06:44 2015 +0100
>>
>>     ARM: v7 setup function should invalidate L1 cache
>>
>>     commit 02b4e2756e01c623cc4dbceae4b07be75252db5b upstream. 
> 
> Ah, then why didn't you send this to the stable@vger.kernel.org mailing
> list so that it can be included upstream so that everyone can benifit
> from the fix, not just the ltsi kernel release?
> 
> Please do that, we never want to have patches in our tree that should be
> in the stable releases instead, that's just rude to the rest of the
> kernel community that you are basing your work on.
> 

The patch "89b8da06b ARM: socfpga: fix build error due to
secondary_startup", even though it's commit log is referencing patch
02b4e2756e01, it's really fixing patch 45be0cdb5323.

Patch 45be0cdb5323 was backported by me to the v4.1-ltsi branch, and is
referenced as:

patches.altera/0020-ARM-socfpga-add-CPU_METHOD_OF_DECLARE-for-Arria-10.patch

So if that explanation is acceptable, please apply patch:

commit 89b8da06ba302dd130df60df7964ccd3ab151cd6

to the v4.1.14-ltsi tree.

Thanks,
Dinh
Greg Kroah-Hartman Jan. 13, 2016, 2:36 a.m. UTC | #6
On Thu, Dec 10, 2015 at 03:01:33PM -0600, Dinh Nguyen wrote:
> On 12/04/2015 11:19 AM, Greg KH wrote:
> > On Fri, Dec 04, 2015 at 10:34:22AM -0600, Dinh Nguyen wrote:
> >> On Fri, 4 Dec 2015, Greg KH wrote:
> >>
> >>> On Mon, Nov 30, 2015 at 11:15:33AM -0600, Dinh Nguyen wrote:
> >>>> On 11/30/2015 11:20 AM, Greg KH wrote:
> >>>>> On Mon, Nov 30, 2015 at 11:02:57AM -0600, dinguyen@opensource.altera.com wrote:
> >>>>>> From: Kevin Hilman <khilman@linaro.org>
> >>>>>>
> >>>>>> After commit 02b4e2756e01 (ARM: v7 setup function should invalidate L1
> >>>>>> cache) the soc specific secondary_startup is removed, causing build
> >>>>>> failures:
> >>>>>>
> >>>>>> ../arch/arm/mach-socfpga/platsmp.c: In function 'socfpga_a10_boot_secondary':
> >>>>>> ../arch/arm/mach-socfpga/platsmp.c:66:140: error: 'socfpga_secondary_startup' undeclared (first use in this function)
> >>>>>> ../arch/arm/mach-socfpga/platsmp.c:66:140: note: each undeclared identifier is reported only once for each function it appears in
> >>>>>>
> >>>>>> To fix, use the generic secondary_startup.
> >>>>>>
> >>>>>> Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
> >>>>>> Signed-off-by: Kevin Hilman <khilman@linaro.org>
> >>>>>> ---
> >>>>>> Hi Greg,
> >>>>>>
> >>>>>> Please consider applying this patch for fix a build error for SoCFPGA on
> >>>>>> 4.1.13-ltsi-rc1
> >>>>>
> >>>>> Is this patch upstream?  If so, what is the git commit id?
> >>>>>
> >>>>
> >>>> Yes, sorry about that. The commit id is:
> >>>>
> >>>> commit 89b8da06ba302dd130df60df7964ccd3ab151cd6
> >>>
> >>> Thanks.  But why is this patch needed?  commit 02b4e2756e01 showed up in
> >>> 4.2-rc1, it's not in the 4.1 tree, and as such, isn't in the 4.1-ltsi
> >>> tree either, so I don't understand why this patch should be applied.
> >>>
> >>
> >> I see the 02b4e2756e01 commit as this in the v4.1.13 branch:
> >>
> >> commit a3595b864a2d64cf5084cbd822be622a4b0f5664
> >> Author: Russell King <rmk+kernel@arm.linux.org.uk>
> >> Date:   Tue May 19 17:06:44 2015 +0100
> >>
> >>     ARM: v7 setup function should invalidate L1 cache
> >>
> >>     commit 02b4e2756e01c623cc4dbceae4b07be75252db5b upstream. 
> > 
> > Ah, then why didn't you send this to the stable@vger.kernel.org mailing
> > list so that it can be included upstream so that everyone can benifit
> > from the fix, not just the ltsi kernel release?
> > 
> > Please do that, we never want to have patches in our tree that should be
> > in the stable releases instead, that's just rude to the rest of the
> > kernel community that you are basing your work on.
> > 
> 
> The patch "89b8da06b ARM: socfpga: fix build error due to
> secondary_startup", even though it's commit log is referencing patch
> 02b4e2756e01, it's really fixing patch 45be0cdb5323.
> 
> Patch 45be0cdb5323 was backported by me to the v4.1-ltsi branch, and is
> referenced as:
> 
> patches.altera/0020-ARM-socfpga-add-CPU_METHOD_OF_DECLARE-for-Arria-10.patch
> 
> So if that explanation is acceptable, please apply patch:
> 
> commit 89b8da06ba302dd130df60df7964ccd3ab151cd6
> 
> to the v4.1.14-ltsi tree.

Sorry for the delay, this is now merged.

greg k-h
diff mbox

Patch

diff --git a/arch/arm/mach-socfpga/platsmp.c b/arch/arm/mach-socfpga/platsmp.c
index 4d2ad3d..c6f1df8 100644
--- a/arch/arm/mach-socfpga/platsmp.c
+++ b/arch/arm/mach-socfpga/platsmp.c
@@ -63,7 +63,7 @@  static int socfpga_a10_boot_secondary(unsigned int cpu, struct task_struct *idle
 		       SOCFPGA_A10_RSTMGR_MODMPURST);
 		memcpy(phys_to_virt(0), &secondary_trampoline, trampoline_size);
 
-		writel(virt_to_phys(socfpga_secondary_startup),
+		writel(virt_to_phys(secondary_startup),
 		       sys_manager_base_addr + (socfpga_cpu1start_addr & 0x00000fff));
 
 		flush_cache_all();