Skip to contentSkip to conversation

maibox:Remove unused functions in the file pcc.c

PATCH RESEND Jassi Brar 3 participants 4 messages Jan 14, 2016 2 messages not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

Jassi Brar

author
#1 lore raw
Quoted 6 lines · Nicholas Krause

This removes the unused function pcc_mbox_request_channel due to having no more callers in this driver or else where in the kernel. In addition remove the function get_pcc_channel now due to this function's only caller pcc_mbox_request_channel being removed from the file pcc.c in this patch too.

CC'ing Ashwin, the author of this api.

#2 lore raw
Quoted 8 lines · Jassi Brar
Quoted 6 lines · Nicholas Krause

This removes the unused function pcc_mbox_request_channel due to having no more callers in this driver or else where in the kernel. In addition remove the function get_pcc_channel now due to this function's only caller pcc_mbox_request_channel being removed from the file pcc.c in this patch too.

CC'ing Ashwin, the author of this api.

Have you looked in -
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/drivers/acpi/cppc_acpi.c
?

Ashwin

#3 lore raw
Quoted 8 lines · Ashwin Chaugule
Quoted 7 lines · Jassi Brar
Quoted 6 lines · Nicholas Krause

This removes the unused function pcc_mbox_request_channel due to having no more callers in this driver or else where in the kernel. In addition remove the function get_pcc_channel now due to this function's only caller pcc_mbox_request_channel being removed from the file pcc.c in this patch too.

Quoted 5 lines
Quoted 1 line

CC'ing Ashwin, the author of this api.

Have you looked in -
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/drivers/acpi/cppc_acpi.c
?

Of course he didn't.

A message that is not in the archive (sent off-list or not yet received): [email protected]

#5 lore raw
Quoted 11 lines · nick
Quoted 6 lines · On 2016-01-14 12:32 PM, [email protected] wrote:
Quoted 3 lines

Have you looked in -
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/tree/drivers/acpi/cppc_acpi.c
?

Of course he didn't.

Or maybe he did a allmodconfig build on x86_64 bit and either that file builds correctly on x86 with

That doesn't excuse not doing a 'git grep pcc_mbox_request_channel' or a 'grep -r pcc_mbox_request_channel .', both of which would have find the caller.

Quoted 3 lines

the patch applied due to it never being use on x86 or Kconfig files incorrectly set for allmodconfig builds on x86 for this file, or maybe my compiler is broken but I doubt that as it works for all other build errors similar to this.

Or you don't have the foggiest clue how Kconfig works, and don't understand why in a 'allmodconfig' this file is *NOT* built.

Hint 1:

grep cppc drivers/acpi/Makefile
obj-$(CONFIG_ACPI_CPPC_LIB) += cppc_acpi.o

Hint 2: In the Kconfig:

config ACPI_CPPC_LIB
bool
depends on ACPI_PROCESSOR
depends on !ACPI_CPU_FREQ_PSS

config ACPI_PROCESSOR

        tristate "Processor"
        depends on X86 || IA64 || ARM64
        select ACPI_PROCESSOR_IDLE if X86 || IA64
        select ACPI_CPU_FREQ_PSS if X86 || IA64

It's left as an exercise for the reader to figure out what happens to ACPI_CPPC_LIB when 'make allmodconfig' sets ACPI_PROCESSOR=m