@@ -1298,7 +1298,7 @@ static void kvm_destroy_vm(struct kvm *kvm)
12981298 * At this point, pending calls to invalidate_range_start()
12991299 * have completed but no more MMU notifiers will run, so
13001300 * mn_active_invalidate_count may remain unbalanced.
1301- * No threads can be waiting in install_new_memslots as the
1301+ * No threads can be waiting in kvm_swap_active_memslots() as the
13021302 * last reference on KVM has been dropped, but freeing
13031303 * memslots would deadlock without this manual intervention.
13041304 */
@@ -1742,13 +1742,13 @@ static void kvm_invalidate_memslot(struct kvm *kvm,
17421742 kvm_arch_flush_shadow_memslot (kvm , old );
17431743 kvm_arch_guest_memory_reclaimed (kvm );
17441744
1745- /* Was released by kvm_swap_active_memslots, reacquire. */
1745+ /* Was released by kvm_swap_active_memslots() , reacquire. */
17461746 mutex_lock (& kvm -> slots_arch_lock );
17471747
17481748 /*
17491749 * Copy the arch-specific field of the newly-installed slot back to the
17501750 * old slot as the arch data could have changed between releasing
1751- * slots_arch_lock in install_new_memslots () and re-acquiring the lock
1751+ * slots_arch_lock in kvm_swap_active_memslots () and re-acquiring the lock
17521752 * above. Writers are required to retrieve memslots *after* acquiring
17531753 * slots_arch_lock, thus the active slot's data is guaranteed to be fresh.
17541754 */
@@ -1810,11 +1810,11 @@ static int kvm_set_memslot(struct kvm *kvm,
18101810 int r ;
18111811
18121812 /*
1813- * Released in kvm_swap_active_memslots.
1813+ * Released in kvm_swap_active_memslots() .
18141814 *
1815- * Must be held from before the current memslots are copied until
1816- * after the new memslots are installed with rcu_assign_pointer,
1817- * then released before the synchronize srcu in kvm_swap_active_memslots.
1815+ * Must be held from before the current memslots are copied until after
1816+ * the new memslots are installed with rcu_assign_pointer, then
1817+ * released before the synchronize srcu in kvm_swap_active_memslots() .
18181818 *
18191819 * When modifying memslots outside of the slots_lock, must be held
18201820 * before reading the pointer to the current memslots until after all
@@ -3866,7 +3866,7 @@ static int create_vcpu_fd(struct kvm_vcpu *vcpu)
38663866#ifdef __KVM_HAVE_ARCH_VCPU_DEBUGFS
38673867static int vcpu_get_pid (void * data , u64 * val )
38683868{
3869- struct kvm_vcpu * vcpu = ( struct kvm_vcpu * ) data ;
3869+ struct kvm_vcpu * vcpu = data ;
38703870 * val = pid_nr (rcu_access_pointer (vcpu -> pid ));
38713871 return 0 ;
38723872}
@@ -5572,8 +5572,7 @@ static int kvm_debugfs_open(struct inode *inode, struct file *file,
55725572 const char * fmt )
55735573{
55745574 int ret ;
5575- struct kvm_stat_data * stat_data = (struct kvm_stat_data * )
5576- inode -> i_private ;
5575+ struct kvm_stat_data * stat_data = inode -> i_private ;
55775576
55785577 /*
55795578 * The debugfs files are a reference to the kvm struct which
@@ -5594,8 +5593,7 @@ static int kvm_debugfs_open(struct inode *inode, struct file *file,
55945593
55955594static int kvm_debugfs_release (struct inode * inode , struct file * file )
55965595{
5597- struct kvm_stat_data * stat_data = (struct kvm_stat_data * )
5598- inode -> i_private ;
5596+ struct kvm_stat_data * stat_data = inode -> i_private ;
55995597
56005598 simple_attr_release (inode , file );
56015599 kvm_put_kvm (stat_data -> kvm );
@@ -5644,7 +5642,7 @@ static int kvm_clear_stat_per_vcpu(struct kvm *kvm, size_t offset)
56445642static int kvm_stat_data_get (void * data , u64 * val )
56455643{
56465644 int r = - EFAULT ;
5647- struct kvm_stat_data * stat_data = ( struct kvm_stat_data * ) data ;
5645+ struct kvm_stat_data * stat_data = data ;
56485646
56495647 switch (stat_data -> kind ) {
56505648 case KVM_STAT_VM :
@@ -5663,7 +5661,7 @@ static int kvm_stat_data_get(void *data, u64 *val)
56635661static int kvm_stat_data_clear (void * data , u64 val )
56645662{
56655663 int r = - EFAULT ;
5666- struct kvm_stat_data * stat_data = ( struct kvm_stat_data * ) data ;
5664+ struct kvm_stat_data * stat_data = data ;
56675665
56685666 if (val )
56695667 return - EINVAL ;
0 commit comments