Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
EtherBone Core
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Projects
EtherBone Core
Commits
2cd3f9fb
Commit
2cd3f9fb
authored
13 years ago
by
Wesley W. Terpstra
Browse files
Options
Downloads
Patches
Plain Diff
These "convenience" functions aren't so convenient.
... encourage people to use the proper API.
parent
71d76024
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
api/etherbone.h
+0
-22
0 additions, 22 deletions
api/etherbone.h
api/glue/device.c
+0
-27
0 additions, 27 deletions
api/glue/device.c
with
0 additions
and
49 deletions
api/etherbone.h
+
0
−
22
View file @
2cd3f9fb
...
...
@@ -442,28 +442,6 @@ void eb_cycle_write_config(eb_cycle_t cycle,
eb_format_t
format
,
eb_data_t
data
);
/* Convenience function for single-write cycle.
* Can return EB_OOM.
*/
EB_PUBLIC
eb_status_t
eb_device_read
(
eb_device_t
device
,
eb_address_t
address
,
eb_width_t
width
,
eb_data_t
*
data
,
eb_user_data_t
user
,
eb_callback_t
cb
);
/* Convenience function for single-read cycle.
* Can return EB_OOM.
*/
EB_PUBLIC
eb_status_t
eb_device_write
(
eb_device_t
device
,
eb_address_t
address
,
eb_width_t
width
,
eb_data_t
data
,
eb_user_data_t
user
,
eb_callback_t
cb
);
/* Operation result accessors */
/* The next operation in the list. EB_NULL = end-of-list */
...
...
This diff is collapsed.
Click to expand it.
api/glue/device.c
+
0
−
27
View file @
2cd3f9fb
...
...
@@ -258,30 +258,3 @@ eb_socket_t eb_device_socket(eb_device_t devicep) {
device
=
EB_DEVICE
(
devicep
);
return
device
->
socket
;
}
eb_status_t
eb_device_read
(
eb_device_t
device
,
eb_address_t
address
,
eb_width_t
width
,
eb_data_t
*
data
,
eb_user_data_t
user
,
eb_callback_t
cb
)
{
eb_cycle_t
cycle
;
cycle
=
eb_cycle_open
(
device
,
user
,
cb
);
if
(
cycle
==
EB_NULL
)
return
EB_OOM
;
eb_cycle_read
(
cycle
,
address
,
width
,
data
);
eb_cycle_close
(
cycle
);
return
EB_OK
;
}
eb_status_t
eb_device_write
(
eb_device_t
device
,
eb_address_t
address
,
eb_width_t
width
,
eb_data_t
data
,
eb_user_data_t
user
,
eb_callback_t
cb
)
{
eb_cycle_t
cycle
;
cycle
=
eb_cycle_open
(
device
,
user
,
cb
);
if
(
cycle
==
EB_NULL
)
return
EB_OOM
;
eb_cycle_write
(
cycle
,
address
,
width
,
data
);
if
(
cb
==
0
)
eb_cycle_close_silently
(
cycle
);
else
eb_cycle_close
(
cycle
);
return
EB_OK
;
}
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment