diff options
author | Stefan Wahren <stefan.wahren@i2se.com> | 2021-10-03 14:32:49 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-10-05 12:21:46 +0200 |
commit | 6649335e1f0c3482a3a86840afdb2448ceb6bff1 (patch) | |
tree | c4b7654563f4c24d28795cbdd3e44d9f83b54e45 /drivers/staging/vc04_services | |
parent | 89cc4218f64061b107eebf2e14c8ebdc933931c1 (diff) |
staging: vchiq_arm: move platform structs to vchiq_arm.c
After merging vchiq_2835_arm.c into vchiq_arm.c some platform structs
doesn't need to exported anymore. So move them into the C file.
Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
Link: https://lore.kernel.org/r/1633264369-998-4-git-send-email-stefan.wahren@i2se.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/vc04_services')
-rw-r--r-- | drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c | 39 | ||||
-rw-r--r-- | drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.h | 39 |
2 files changed, 39 insertions, 39 deletions
diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c index 9c424e19fc1d..6fbafdfe340f 100644 --- a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c +++ b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c @@ -68,6 +68,11 @@ struct vchiq_state g_state; static struct platform_device *bcm2835_camera; static struct platform_device *bcm2835_audio; +struct vchiq_drvdata { + const unsigned int cache_line_size; + struct rpi_firmware *fw; +}; + static struct vchiq_drvdata bcm2835_drvdata = { .cache_line_size = 32, }; @@ -76,6 +81,40 @@ static struct vchiq_drvdata bcm2836_drvdata = { .cache_line_size = 64, }; +struct vchiq_arm_state { + /* Keepalive-related data */ + struct task_struct *ka_thread; + struct completion ka_evt; + atomic_t ka_use_count; + atomic_t ka_use_ack_count; + atomic_t ka_release_count; + + rwlock_t susp_res_lock; + + struct vchiq_state *state; + + /* + * Global use count for videocore. + * This is equal to the sum of the use counts for all services. When + * this hits zero the videocore suspend procedure will be initiated. + */ + int videocore_use_count; + + /* + * Use count to track requests from videocore peer. + * This use count is not associated with a service, so needs to be + * tracked separately with the state. + */ + int peer_use_count; + + /* + * Flag to indicate that the first vchiq connect has made it through. + * This means that both sides should be fully ready, and we should + * be able to suspend after this point. + */ + int first_connect; +}; + struct vchiq_2835_state { int inited; struct vchiq_arm_state arm_state; diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.h b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.h index c77d5ab462b2..2aa46b119a46 100644 --- a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.h +++ b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.h @@ -25,45 +25,6 @@ enum USE_TYPE_E { USE_TYPE_VCHIQ }; -struct vchiq_arm_state { - /* Keepalive-related data */ - struct task_struct *ka_thread; - struct completion ka_evt; - atomic_t ka_use_count; - atomic_t ka_use_ack_count; - atomic_t ka_release_count; - - rwlock_t susp_res_lock; - - struct vchiq_state *state; - - /* - * Global use count for videocore. - * This is equal to the sum of the use counts for all services. When - * this hits zero the videocore suspend procedure will be initiated. - */ - int videocore_use_count; - - /* - * Use count to track requests from videocore peer. - * This use count is not associated with a service, so needs to be - * tracked separately with the state. - */ - int peer_use_count; - - /* - * Flag to indicate that the first vchiq connect has made it through. - * This means that both sides should be fully ready, and we should - * be able to suspend after this point. - */ - int first_connect; -}; - -struct vchiq_drvdata { - const unsigned int cache_line_size; - struct rpi_firmware *fw; -}; - struct user_service { struct vchiq_service *service; void __user *userdata; |