bfa_defs_lport.h 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. /*
  2. * Copyright (c) 2005-2009 Brocade Communications Systems, Inc.
  3. * All rights reserved
  4. * www.brocade.com
  5. *
  6. * Linux driver for Brocade Fibre Channel Host Bus Adapter.
  7. *
  8. * This program is free software; you can redistribute it and/or modify it
  9. * under the terms of the GNU General Public License (GPL) Version 2 as
  10. * published by the Free Software Foundation
  11. *
  12. * This program is distributed in the hope that it will be useful, but
  13. * WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  15. * General Public License for more details.
  16. */
  17. #ifndef __BFA_DEFS_LPORT_H__
  18. #define __BFA_DEFS_LPORT_H__
  19. #include <defs/bfa_defs_types.h>
  20. #include <defs/bfa_defs_port.h>
  21. /**
  22. * BFA AEN logical port events.
  23. * Arguments below are in BFAL context from Mgmt
  24. * BFA_LPORT_AEN_NEW: [in]: None [out]: vf_id, ppwwn, lpwwn, roles
  25. * BFA_LPORT_AEN_DELETE: [in]: lpwwn [out]: vf_id, ppwwn. lpwwn, roles
  26. * BFA_LPORT_AEN_ONLINE: [in]: lpwwn [out]: vf_id, ppwwn. lpwwn, roles
  27. * BFA_LPORT_AEN_OFFLINE: [in]: lpwwn [out]: vf_id, ppwwn. lpwwn, roles
  28. * BFA_LPORT_AEN_DISCONNECT:[in]: lpwwn [out]: vf_id, ppwwn. lpwwn, roles
  29. * BFA_LPORT_AEN_NEW_PROP: [in]: None [out]: vf_id, ppwwn. lpwwn, roles
  30. * BFA_LPORT_AEN_DELETE_PROP: [in]: lpwwn [out]: vf_id, ppwwn. lpwwn, roles
  31. * BFA_LPORT_AEN_NEW_STANDARD: [in]: None [out]: vf_id, ppwwn. lpwwn, roles
  32. * BFA_LPORT_AEN_DELETE_STANDARD: [in]: lpwwn [out]: vf_id, ppwwn. lpwwn, roles
  33. * BFA_LPORT_AEN_NPIV_DUP_WWN: [in]: lpwwn [out]: vf_id, ppwwn. lpwwn, roles
  34. * BFA_LPORT_AEN_NPIV_FABRIC_MAX: [in]: lpwwn [out]: vf_id, ppwwn. lpwwn, roles
  35. * BFA_LPORT_AEN_NPIV_UNKNOWN: [in]: lpwwn [out]: vf_id, ppwwn. lpwwn, roles
  36. */
  37. enum bfa_lport_aen_event {
  38. BFA_LPORT_AEN_NEW = 1, /* LPort created event */
  39. BFA_LPORT_AEN_DELETE = 2, /* LPort deleted event */
  40. BFA_LPORT_AEN_ONLINE = 3, /* LPort online event */
  41. BFA_LPORT_AEN_OFFLINE = 4, /* LPort offline event */
  42. BFA_LPORT_AEN_DISCONNECT = 5, /* LPort disconnect event */
  43. BFA_LPORT_AEN_NEW_PROP = 6, /* VPort created event */
  44. BFA_LPORT_AEN_DELETE_PROP = 7, /* VPort deleted event */
  45. BFA_LPORT_AEN_NEW_STANDARD = 8, /* VPort created event */
  46. BFA_LPORT_AEN_DELETE_STANDARD = 9, /* VPort deleted event */
  47. BFA_LPORT_AEN_NPIV_DUP_WWN = 10, /* VPort configured with
  48. * duplicate WWN event
  49. */
  50. BFA_LPORT_AEN_NPIV_FABRIC_MAX = 11, /* Max NPIV in fabric/fport */
  51. BFA_LPORT_AEN_NPIV_UNKNOWN = 12, /* Unknown NPIV Error code event */
  52. };
  53. /**
  54. * BFA AEN event data structure
  55. */
  56. struct bfa_lport_aen_data_s {
  57. u16 vf_id; /* vf_id of this logical port */
  58. u16 rsvd;
  59. enum bfa_port_role roles; /* Logical port mode,IM/TM/IP etc */
  60. wwn_t ppwwn; /* WWN of its physical port */
  61. wwn_t lpwwn; /* WWN of this logical port */
  62. };
  63. #endif /* __BFA_DEFS_LPORT_H__ */