[Xenomai-git] Alexis Berlemont : analogy: change the context's role (broken)
Module: xenomai-head Branch: master Commit: e1e19708538fed4b2d105db7300ac6822dfae3e4 URL: http://git.xenomai.org/?p=xenomai-head.git;a=commit;h=e1e19708538fed4b2d105db7300ac6822dfae3e4 Author: Alexis Berlemont Date: Sun May 16 23:11:47 2010 +0200 analogy: change the context's role (broken) --- include/analogy/context.h | 27 +-- 1 files changed, 9 insertions(+), 18 deletions(-) diff --git a/include/analogy/context.h b/include/analogy/context.h index 7bd225a..d30bbba 100644 --- a/include/analogy/context.h +++ b/include/analogy/context.h @@ -25,29 +25,20 @@ #if defined(__KERNEL__) && !defined(DOXYGEN_CPP) -#include - struct a4l_device; +struct a4l_buffer; -struct a4l_context { - - /* This field is redundant with the following parameters; - setting it at the head of the structure may save - useless operations */ - struct a4l_device *dev; +struct a4l_device_context { + /* No need to hold user_info, thanks to container_of, we could + get it back */ rtdm_user_info_t *user_info; - struct rtdm_dev_context *rtdm_cxt; -}; -typedef struct a4l_context a4l_cxt_t; -#define a4l_get_minor(x) ((x)->rtdm_cxt->device->device_id) + struct a4l_device *dev; /* Which is retrieved thanks to minor + at open time */ -#define a4l_init_cxt(c, u, x) \ -{ \ - (x)->rtdm_cxt = c; \ - (x)->user_info = u; \ - (x)->dev = NULL;\ -} + struct buffer buffer; /* The buffer field is extracted from +the transfer structure */ +}; #endif /* __KERNEL__ && !DOXYGEN_CPP */ ___ Xenomai-git mailing list Xenomai-git@gna.org https://mail.gna.org/listinfo/xenomai-git
[Xenomai-git] Alexis Berlemont : analogy: change the context's role (broken)
Module: xenomai-2.5 Branch: master Commit: e1e19708538fed4b2d105db7300ac6822dfae3e4 URL: http://git.xenomai.org/?p=xenomai-2.5.git;a=commit;h=e1e19708538fed4b2d105db7300ac6822dfae3e4 Author: Alexis Berlemont Date: Sun May 16 23:11:47 2010 +0200 analogy: change the context's role (broken) --- include/analogy/context.h | 27 +-- 1 files changed, 9 insertions(+), 18 deletions(-) diff --git a/include/analogy/context.h b/include/analogy/context.h index 7bd225a..d30bbba 100644 --- a/include/analogy/context.h +++ b/include/analogy/context.h @@ -25,29 +25,20 @@ #if defined(__KERNEL__) && !defined(DOXYGEN_CPP) -#include - struct a4l_device; +struct a4l_buffer; -struct a4l_context { - - /* This field is redundant with the following parameters; - setting it at the head of the structure may save - useless operations */ - struct a4l_device *dev; +struct a4l_device_context { + /* No need to hold user_info, thanks to container_of, we could + get it back */ rtdm_user_info_t *user_info; - struct rtdm_dev_context *rtdm_cxt; -}; -typedef struct a4l_context a4l_cxt_t; -#define a4l_get_minor(x) ((x)->rtdm_cxt->device->device_id) + struct a4l_device *dev; /* Which is retrieved thanks to minor + at open time */ -#define a4l_init_cxt(c, u, x) \ -{ \ - (x)->rtdm_cxt = c; \ - (x)->user_info = u; \ - (x)->dev = NULL;\ -} + struct buffer buffer; /* The buffer field is extracted from +the transfer structure */ +}; #endif /* __KERNEL__ && !DOXYGEN_CPP */ ___ Xenomai-git mailing list Xenomai-git@gna.org https://mail.gna.org/listinfo/xenomai-git
[Xenomai-git] Alexis Berlemont : analogy: change the context's role (broken)
Module: xenomai-abe Branch: analogy Commit: e1e19708538fed4b2d105db7300ac6822dfae3e4 URL: http://git.xenomai.org/?p=xenomai-abe.git;a=commit;h=e1e19708538fed4b2d105db7300ac6822dfae3e4 Author: Alexis Berlemont Date: Sun May 16 23:11:47 2010 +0200 analogy: change the context's role (broken) --- include/analogy/context.h | 27 +-- 1 files changed, 9 insertions(+), 18 deletions(-) diff --git a/include/analogy/context.h b/include/analogy/context.h index 7bd225a..d30bbba 100644 --- a/include/analogy/context.h +++ b/include/analogy/context.h @@ -25,29 +25,20 @@ #if defined(__KERNEL__) && !defined(DOXYGEN_CPP) -#include - struct a4l_device; +struct a4l_buffer; -struct a4l_context { - - /* This field is redundant with the following parameters; - setting it at the head of the structure may save - useless operations */ - struct a4l_device *dev; +struct a4l_device_context { + /* No need to hold user_info, thanks to container_of, we could + get it back */ rtdm_user_info_t *user_info; - struct rtdm_dev_context *rtdm_cxt; -}; -typedef struct a4l_context a4l_cxt_t; -#define a4l_get_minor(x) ((x)->rtdm_cxt->device->device_id) + struct a4l_device *dev; /* Which is retrieved thanks to minor + at open time */ -#define a4l_init_cxt(c, u, x) \ -{ \ - (x)->rtdm_cxt = c; \ - (x)->user_info = u; \ - (x)->dev = NULL;\ -} + struct buffer buffer; /* The buffer field is extracted from +the transfer structure */ +}; #endif /* __KERNEL__ && !DOXYGEN_CPP */ ___ Xenomai-git mailing list Xenomai-git@gna.org https://mail.gna.org/listinfo/xenomai-git
[Xenomai-git] Alexis Berlemont : analogy: change the context's role (broken)
Module: xenomai-abe Branch: analogy Commit: 379d6ce235cbb9b93d931e9bc6da23882814cbd2 URL: http://git.xenomai.org/?p=xenomai-abe.git;a=commit;h=379d6ce235cbb9b93d931e9bc6da23882814cbd2 Author: Alexis Berlemont Date: Sun May 16 23:11:47 2010 +0200 analogy: change the context's role (broken) --- include/analogy/context.h | 27 +-- 1 files changed, 9 insertions(+), 18 deletions(-) diff --git a/include/analogy/context.h b/include/analogy/context.h index 7bd225a..d30bbba 100644 --- a/include/analogy/context.h +++ b/include/analogy/context.h @@ -25,29 +25,20 @@ #if defined(__KERNEL__) && !defined(DOXYGEN_CPP) -#include - struct a4l_device; +struct a4l_buffer; -struct a4l_context { - - /* This field is redundant with the following parameters; - setting it at the head of the structure may save - useless operations */ - struct a4l_device *dev; +struct a4l_device_context { + /* No need to hold user_info, thanks to container_of, we could + get it back */ rtdm_user_info_t *user_info; - struct rtdm_dev_context *rtdm_cxt; -}; -typedef struct a4l_context a4l_cxt_t; -#define a4l_get_minor(x) ((x)->rtdm_cxt->device->device_id) + struct a4l_device *dev; /* Which is retrieved thanks to minor + at open time */ -#define a4l_init_cxt(c, u, x) \ -{ \ - (x)->rtdm_cxt = c; \ - (x)->user_info = u; \ - (x)->dev = NULL;\ -} + struct buffer buffer; /* The buffer field is extracted from +the transfer structure */ +}; #endif /* __KERNEL__ && !DOXYGEN_CPP */ ___ Xenomai-git mailing list Xenomai-git@gna.org https://mail.gna.org/listinfo/xenomai-git
[Xenomai-git] Alexis Berlemont : analogy: change the context's role (broken)
Module: xenomai-abe Branch: analogy Commit: 4480b6ebfe57954f59177e272891890e675c7a1f URL: http://git.xenomai.org/?p=xenomai-abe.git;a=commit;h=4480b6ebfe57954f59177e272891890e675c7a1f Author: Alexis Berlemont Date: Sun May 16 23:11:47 2010 +0200 analogy: change the context's role (broken) --- include/analogy/context.h | 27 +-- 1 files changed, 9 insertions(+), 18 deletions(-) diff --git a/include/analogy/context.h b/include/analogy/context.h index 7bd225a..d30bbba 100644 --- a/include/analogy/context.h +++ b/include/analogy/context.h @@ -25,29 +25,20 @@ #if defined(__KERNEL__) && !defined(DOXYGEN_CPP) -#include - struct a4l_device; +struct a4l_buffer; -struct a4l_context { - - /* This field is redundant with the following parameters; - setting it at the head of the structure may save - useless operations */ - struct a4l_device *dev; +struct a4l_device_context { + /* No need to hold user_info, thanks to container_of, we could + get it back */ rtdm_user_info_t *user_info; - struct rtdm_dev_context *rtdm_cxt; -}; -typedef struct a4l_context a4l_cxt_t; -#define a4l_get_minor(x) ((x)->rtdm_cxt->device->device_id) + struct a4l_device *dev; /* Which is retrieved thanks to minor + at open time */ -#define a4l_init_cxt(c, u, x) \ -{ \ - (x)->rtdm_cxt = c; \ - (x)->user_info = u; \ - (x)->dev = NULL;\ -} + struct buffer buffer; /* The buffer field is extracted from +the transfer structure */ +}; #endif /* __KERNEL__ && !DOXYGEN_CPP */ ___ Xenomai-git mailing list Xenomai-git@gna.org https://mail.gna.org/listinfo/xenomai-git
[Xenomai-git] Alexis Berlemont : analogy: change the context's role (broken)
Module: xenomai-abe Branch: experimental Commit: 4480b6ebfe57954f59177e272891890e675c7a1f URL: http://git.xenomai.org/?p=xenomai-abe.git;a=commit;h=4480b6ebfe57954f59177e272891890e675c7a1f Author: Alexis Berlemont Date: Sun May 16 23:11:47 2010 +0200 analogy: change the context's role (broken) --- include/analogy/context.h | 27 +-- 1 files changed, 9 insertions(+), 18 deletions(-) diff --git a/include/analogy/context.h b/include/analogy/context.h index 7bd225a..d30bbba 100644 --- a/include/analogy/context.h +++ b/include/analogy/context.h @@ -25,29 +25,20 @@ #if defined(__KERNEL__) && !defined(DOXYGEN_CPP) -#include - struct a4l_device; +struct a4l_buffer; -struct a4l_context { - - /* This field is redundant with the following parameters; - setting it at the head of the structure may save - useless operations */ - struct a4l_device *dev; +struct a4l_device_context { + /* No need to hold user_info, thanks to container_of, we could + get it back */ rtdm_user_info_t *user_info; - struct rtdm_dev_context *rtdm_cxt; -}; -typedef struct a4l_context a4l_cxt_t; -#define a4l_get_minor(x) ((x)->rtdm_cxt->device->device_id) + struct a4l_device *dev; /* Which is retrieved thanks to minor + at open time */ -#define a4l_init_cxt(c, u, x) \ -{ \ - (x)->rtdm_cxt = c; \ - (x)->user_info = u; \ - (x)->dev = NULL;\ -} + struct buffer buffer; /* The buffer field is extracted from +the transfer structure */ +}; #endif /* __KERNEL__ && !DOXYGEN_CPP */ ___ Xenomai-git mailing list Xenomai-git@gna.org https://mail.gna.org/listinfo/xenomai-git
[Xenomai-git] Alexis Berlemont : analogy: change the context's role (broken)
Module: xenomai-abe Branch: experimental Commit: 7c8731064517fc6b388b51af35e434bf6d6c9ce0 URL: http://git.xenomai.org/?p=xenomai-abe.git;a=commit;h=7c8731064517fc6b388b51af35e434bf6d6c9ce0 Author: Alexis Berlemont Date: Sun May 16 23:11:47 2010 +0200 analogy: change the context's role (broken) --- include/analogy/context.h | 27 +-- 1 files changed, 9 insertions(+), 18 deletions(-) diff --git a/include/analogy/context.h b/include/analogy/context.h index 7bd225a..d30bbba 100644 --- a/include/analogy/context.h +++ b/include/analogy/context.h @@ -25,29 +25,20 @@ #if defined(__KERNEL__) && !defined(DOXYGEN_CPP) -#include - struct a4l_device; +struct a4l_buffer; -struct a4l_context { - - /* This field is redundant with the following parameters; - setting it at the head of the structure may save - useless operations */ - struct a4l_device *dev; +struct a4l_device_context { + /* No need to hold user_info, thanks to container_of, we could + get it back */ rtdm_user_info_t *user_info; - struct rtdm_dev_context *rtdm_cxt; -}; -typedef struct a4l_context a4l_cxt_t; -#define a4l_get_minor(x) ((x)->rtdm_cxt->device->device_id) + struct a4l_device *dev; /* Which is retrieved thanks to minor + at open time */ -#define a4l_init_cxt(c, u, x) \ -{ \ - (x)->rtdm_cxt = c; \ - (x)->user_info = u; \ - (x)->dev = NULL;\ -} + struct buffer buffer; /* The buffer field is extracted from +the transfer structure */ +}; #endif /* __KERNEL__ && !DOXYGEN_CPP */ ___ Xenomai-git mailing list Xenomai-git@gna.org https://mail.gna.org/listinfo/xenomai-git