Steven Moreland | 7baf725 | 2018-05-25 16:23:37 -0700 | [diff] [blame] | 1 | type mediacodec, domain, mlstrustedsubject; |
| 2 | type mediacodec_exec, exec_type, vendor_file_type, file_type; |
| 3 | |
| 4 | init_daemon_domain(mediacodec) |
| 5 | |
| 6 | not_full_treble(` |
| 7 | # on legacy devices, continue to allow /dev/binder traffic |
| 8 | binder_use(mediacodec) |
| 9 | binder_service(mediacodec) |
| 10 | add_service(mediacodec, mediacodec_service) |
| 11 | allow mediacodec mediametrics_service:service_manager find; |
| 12 | allow mediacodec surfaceflinger_service:service_manager find; |
| 13 | ') |
| 14 | |
Chong Zhang | bdbfff1 | 2018-09-20 12:07:44 -0700 | [diff] [blame] | 15 | # can route /dev/binder traffic to /dev/vndbinder |
| 16 | vndbinder_use(mediacodec) |
| 17 | |
Steven Moreland | 7baf725 | 2018-05-25 16:23:37 -0700 | [diff] [blame] | 18 | hal_server_domain(mediacodec, hal_omx) |
| 19 | |
| 20 | hal_client_domain(mediacodec, hal_allocator) |
Steven Moreland | 7baf725 | 2018-05-25 16:23:37 -0700 | [diff] [blame] | 21 | hal_client_domain(mediacodec, hal_graphics_allocator) |
Chong Zhang | bdbfff1 | 2018-09-20 12:07:44 -0700 | [diff] [blame] | 22 | |
| 23 | allow mediacodec gpu_device:chr_file rw_file_perms; |
| 24 | allow mediacodec video_device:chr_file rw_file_perms; |
| 25 | allow mediacodec video_device:dir search; |
| 26 | |