Changeset 9cc4b2b4 in mainline for uspace/drv/fb/amdm37x_dispc/main.c
- Timestamp:
- 2013-01-20T21:06:33Z (11 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 96228d0
- Parents:
- 74db5a1
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/fb/amdm37x_dispc/main.c
r74db5a1 r9cc4b2b4 62 62 return ENOMEM; 63 63 } 64 65 /* Hw part */ 64 66 amdm37x_dispc_t *dispc = 65 ddf_ fun_data_alloc(fun, sizeof(amdm37x_dispc_t));67 ddf_dev_data_alloc(dev, sizeof(amdm37x_dispc_t)); 66 68 if (!dispc) { 67 69 ddf_log_error("Failed to allocate dispc structure\n"); … … 69 71 return ENOMEM; 70 72 } 71 ddf_fun_set_ops(fun, &graph_fun_ops); 73 72 74 int ret = amdm37x_dispc_init(dispc); 73 75 if (ret != EOK) { … … 76 78 return ret; 77 79 } 80 81 /* Visualizer part */ 82 visualizer_t *vis = ddf_fun_data_alloc(fun, sizeof(visualizer_t)); 83 if (!vis) { 84 ddf_log_error("Failed to allocate visualizer structure\n"); 85 ddf_fun_destroy(fun); 86 return ENOMEM; 87 } 88 89 graph_init_visualizer(vis); 90 vis->def_mode_idx = 0; // TODO: What is this? Why is this not handled 91 // via init? 92 vis->ops = amdm37x_dispc_vis_ops; 93 vis->dev_ctx = dispc; 94 vis->reg_svc_handle = ddf_fun_get_handle(fun); 95 96 ddf_fun_set_ops(fun, &graph_fun_ops); 78 97 ret = ddf_fun_bind(fun); 79 98 if (ret != EOK) { … … 83 102 return ret; 84 103 } 104 ddf_fun_add_to_category(fun, "visualizer"); 85 105 return EOK; 86 106 }
Note:
See TracChangeset
for help on using the changeset viewer.