Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Drivers: hv: Rename 'alloced' to 'allocated'

'Alloced' is not a real word and only saves us two letters, let's
use 'allocated' instead.

No functional change intended.

Signed-off-by: Vitaly Kuznetsov <vkuznets@redhat.com>
Reviewed-by: Michael Kelley <mikelley@microsoft.com>
Link: https://lore.kernel.org/r/20220128103412.3033736-2-vkuznets@redhat.com
Signed-off-by: Wei Liu <wei.liu@kernel.org>

authored by

Vitaly Kuznetsov and committed by
Wei Liu
de96e8a0 a70d298c

+17 -17
+9 -9
drivers/hv/channel_mgmt.c
··· 459 459 * init_vp_index() can (re-)use the CPU. 460 460 */ 461 461 if (hv_is_perf_channel(channel)) 462 - hv_clear_alloced_cpu(channel->target_cpu); 462 + hv_clear_allocated_cpu(channel->target_cpu); 463 463 464 464 /* 465 465 * Upon suspend, an in-use hv_sock channel is marked as "rescinded" and ··· 728 728 bool perf_chn = hv_is_perf_channel(channel); 729 729 u32 i, ncpu = num_online_cpus(); 730 730 cpumask_var_t available_mask; 731 - struct cpumask *alloced_mask; 731 + struct cpumask *allocated_mask; 732 732 u32 target_cpu; 733 733 int numa_node; 734 734 ··· 745 745 */ 746 746 channel->target_cpu = VMBUS_CONNECT_CPU; 747 747 if (perf_chn) 748 - hv_set_alloced_cpu(VMBUS_CONNECT_CPU); 748 + hv_set_allocated_cpu(VMBUS_CONNECT_CPU); 749 749 return; 750 750 } 751 751 ··· 760 760 continue; 761 761 break; 762 762 } 763 - alloced_mask = &hv_context.hv_numa_map[numa_node]; 763 + allocated_mask = &hv_context.hv_numa_map[numa_node]; 764 764 765 - if (cpumask_weight(alloced_mask) == 765 + if (cpumask_weight(allocated_mask) == 766 766 cpumask_weight(cpumask_of_node(numa_node))) { 767 767 /* 768 768 * We have cycled through all the CPUs in the node; 769 - * reset the alloced map. 769 + * reset the allocated map. 770 770 */ 771 - cpumask_clear(alloced_mask); 771 + cpumask_clear(allocated_mask); 772 772 } 773 773 774 - cpumask_xor(available_mask, alloced_mask, 774 + cpumask_xor(available_mask, allocated_mask, 775 775 cpumask_of_node(numa_node)); 776 776 777 777 target_cpu = cpumask_first(available_mask); 778 - cpumask_set_cpu(target_cpu, alloced_mask); 778 + cpumask_set_cpu(target_cpu, allocated_mask); 779 779 780 780 if (channel->offermsg.offer.sub_channel_index >= ncpu || 781 781 i > ncpu || !hv_cpuself_used(target_cpu, channel))
+7 -7
drivers/hv/hyperv_vmbus.h
··· 405 405 return vmbus_devs[channel->device_id].perf_device; 406 406 } 407 407 408 - static inline bool hv_is_alloced_cpu(unsigned int cpu) 408 + static inline bool hv_is_allocated_cpu(unsigned int cpu) 409 409 { 410 410 struct vmbus_channel *channel, *sc; 411 411 ··· 427 427 return false; 428 428 } 429 429 430 - static inline void hv_set_alloced_cpu(unsigned int cpu) 430 + static inline void hv_set_allocated_cpu(unsigned int cpu) 431 431 { 432 432 cpumask_set_cpu(cpu, &hv_context.hv_numa_map[cpu_to_node(cpu)]); 433 433 } 434 434 435 - static inline void hv_clear_alloced_cpu(unsigned int cpu) 435 + static inline void hv_clear_allocated_cpu(unsigned int cpu) 436 436 { 437 - if (hv_is_alloced_cpu(cpu)) 437 + if (hv_is_allocated_cpu(cpu)) 438 438 return; 439 439 cpumask_clear_cpu(cpu, &hv_context.hv_numa_map[cpu_to_node(cpu)]); 440 440 } 441 441 442 - static inline void hv_update_alloced_cpus(unsigned int old_cpu, 442 + static inline void hv_update_allocated_cpus(unsigned int old_cpu, 443 443 unsigned int new_cpu) 444 444 { 445 - hv_set_alloced_cpu(new_cpu); 446 - hv_clear_alloced_cpu(old_cpu); 445 + hv_set_allocated_cpu(new_cpu); 446 + hv_clear_allocated_cpu(old_cpu); 447 447 } 448 448 449 449 #ifdef CONFIG_HYPERV_TESTING
+1 -1
drivers/hv/vmbus_drv.c
··· 1874 1874 1875 1875 /* See init_vp_index(). */ 1876 1876 if (hv_is_perf_channel(channel)) 1877 - hv_update_alloced_cpus(origin_cpu, target_cpu); 1877 + hv_update_allocated_cpus(origin_cpu, target_cpu); 1878 1878 1879 1879 /* Currently set only for storvsc channels. */ 1880 1880 if (channel->change_target_cpu_callback) {