summaryrefslogtreecommitdiffstats
path: root/bsps/shared/grlib
diff options
context:
space:
mode:
Diffstat (limited to 'bsps/shared/grlib')
-rw-r--r--bsps/shared/grlib/1553/b1553brm.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/bsps/shared/grlib/1553/b1553brm.c b/bsps/shared/grlib/1553/b1553brm.c
index 57ef70126b..694f5850f2 100644
--- a/bsps/shared/grlib/1553/b1553brm.c
+++ b/bsps/shared/grlib/1553/b1553brm.c
@@ -994,8 +994,8 @@ static rtems_device_driver brm_control(rtems_device_major_number major, rtems_de
unsigned int i=0;
unsigned short ctrl, oper, cw1, cw2;
rtems_libio_ioctl_args_t *ioarg = (rtems_libio_ioctl_args_t *) arg;
- unsigned int *data = ioarg->buffer;
- struct bc_msg *cmd_list = (struct bc_msg *) ioarg->buffer;
+ unsigned int *data;
+ struct bc_msg *cmd_list;
brm_priv *brm;
struct drvmgr_dev *dev;
rtems_device_driver ret;
@@ -1013,6 +1013,9 @@ static rtems_device_driver brm_control(rtems_device_major_number major, rtems_de
return RTEMS_INVALID_NAME;
}
+ data = ioarg->buffer;
+ cmd_list = (struct bc_msg *) ioarg->buffer;
+
ioarg->ioctl_return = 0;
switch (ioarg->command) {