SlideShare une entreprise Scribd logo
1  sur  9
Télécharger pour lire hors ligne
tgtd illustration
                          based on https://github.com/fujita/tgt




Tuesday, November 8, 11                                            1
General Arch
                     epoll         iSCSI, iSER,                            bst: aio, rdwr,
                                   FCoE, etc.                              null, sg, ssc



                             low level                                backing
           initiator
                              drivers    con                           stores
                                               n
                                                               R &W
                                              target
                                                                           mmc, osd,
                                                   Core                    sbc, scc, smc,
                                                                           ssc
                                                       lu     SC
                                           a  sk                SI
                                         mt
                                                                       spc &
           tgtadm             mgmt
                                                                      devices
                                                     utils,
                                                   common

Tuesday, November 8, 11                                                                      2
Mgmt Routine
                                              If req Len>
                                              tgtadm_req    tgt_mgmt
      tgtadm send
     commands here                  mtask_handler
                                    HDR_RECV                  sys_mgmt
                                    PDU_RECV
                                                              target_mgmt

                          IPC:                      mgmt_task portal_mgmt

                                                              device_mgmt
                                       mtask_handler
                                       RSP_SEND               account_mgmt

                                                              connection_mgmt




Tuesday, November 8, 11                                                         3
State Transition of Conn
                                                             Security           Security
                                      Security                auth               Done


                     Free                        Security
                                                  login

                                                                                Security
                                       Login                 Login full
                                                                                  full
     Only for iSER




                        Init
                       Start
                                                                Full            Kernel
                      Ready              Network Error


                        Proto Error                                    Logout
                                        Exit                Close                Scsi

Tuesday, November 8, 11                                                                    4
Cmd rx in iscsid 1
                                             Immediate:
     OpXX                 iscsi_task_queue   iscsi_task_ececute
                                             Other:
     OP_DATA_OUT                               expected SNs:
                                               iscsi_task_execute
                                               Others:
      iscsi_task_ececute
                                               Add to pending list
                   NOOP_OUT/LOGOUT:
                   Set EPOLLIN|EPOLLOUT         queue:

                   SCSI_CMD:                    target_cmd_queue
                                                                 ... target.c
                   iscsi_scsi_cmd_execute       all:

                   SCSI_TMFUNC:
                                                Set EPOLLIN|EPOLLOUT
                   iscsi_tm_execute          target_mgmt_request
                                                               ... target.c


Tuesday, November 8, 11                                                         5
Cmd rx in iscsid 2
     OpXX

     OP_DATA_OUT               iscsi_data_out_rx_done


                                   Do nothing

                                   FINAL && not pending:
                                   iscsi_scsi_cmd_execute
                                          ... as in prev page



Tuesday, November 8, 11                                         6
SCSI Cmd Processing            In target.c, scsi.c, & devs


                           cmd_perform ==

                           scsi_cmd_perfor

                          scsi_cmd_queued
                              Processed later

                          dev_type_template.ops[op]. cmd_perfor

                                sbc_rw, sbc_sync_cache               BS

                                Others processed in sbc.c or spc.c

Tuesday, November 8, 11                                                       7
Backing Storage
                                 bs_init      bs_thread_info follows lu

                    Create LU

                                 bs_open         pathname, fd, size




                   Dev request       bs_cmd_submit(cmd)

                    Destroy LU       bs_close, bs_exit

Tuesday, November 8, 11                                                   8
That's All.
                             Thanks!




Tuesday, November 8, 11                 9

Contenu connexe

Similaire à Tgtd illustration

[Ruxcon 2011] Post Memory Corruption Memory Analysis
[Ruxcon 2011] Post Memory Corruption Memory Analysis[Ruxcon 2011] Post Memory Corruption Memory Analysis
[Ruxcon 2011] Post Memory Corruption Memory AnalysisMoabi.com
 
IRQs: the Hard, the Soft, the Threaded and the Preemptible
IRQs: the Hard, the Soft, the Threaded and the PreemptibleIRQs: the Hard, the Soft, the Threaded and the Preemptible
IRQs: the Hard, the Soft, the Threaded and the PreemptibleAlison Chaiken
 
[ZigBee 嵌入式系統] ZigBee 應用實作 - 使用 TI Z-Stack Firmware
[ZigBee 嵌入式系統] ZigBee 應用實作 - 使用 TI Z-Stack Firmware[ZigBee 嵌入式系統] ZigBee 應用實作 - 使用 TI Z-Stack Firmware
[ZigBee 嵌入式系統] ZigBee 應用實作 - 使用 TI Z-Stack FirmwareSimen Li
 
[CCC-28c3] Post Memory Corruption Memory Analysis
[CCC-28c3] Post Memory Corruption Memory Analysis[CCC-28c3] Post Memory Corruption Memory Analysis
[CCC-28c3] Post Memory Corruption Memory AnalysisMoabi.com
 
RTOS implementation
RTOS implementationRTOS implementation
RTOS implementationRajan Kumar
 
[Kiwicon 2011] Post Memory Corruption Memory Analysis
[Kiwicon 2011] Post Memory Corruption Memory Analysis[Kiwicon 2011] Post Memory Corruption Memory Analysis
[Kiwicon 2011] Post Memory Corruption Memory AnalysisMoabi.com
 
Linux-without-a-bootloader
Linux-without-a-bootloaderLinux-without-a-bootloader
Linux-without-a-bootloaderNishanth Menon
 
Code Red Security
Code Red SecurityCode Red Security
Code Red SecurityAmr Ali
 
Kernel Recipes 2015 - Porting Linux to a new processor architecture
Kernel Recipes 2015 - Porting Linux to a new processor architectureKernel Recipes 2015 - Porting Linux to a new processor architecture
Kernel Recipes 2015 - Porting Linux to a new processor architectureAnne Nicolas
 
[HITB Malaysia 2011] Exploit Automation
[HITB Malaysia 2011] Exploit Automation[HITB Malaysia 2011] Exploit Automation
[HITB Malaysia 2011] Exploit AutomationMoabi.com
 
Gluster as Block Store in Containers
Gluster as Block Store in ContainersGluster as Block Store in Containers
Gluster as Block Store in ContainersGluster.org
 
OpenDNSSEC RIPE58
OpenDNSSEC RIPE58OpenDNSSEC RIPE58
OpenDNSSEC RIPE58pawal
 
A little systemtap
A little systemtapA little systemtap
A little systemtapyang bingwu
 
A little systemtap
A little systemtapA little systemtap
A little systemtapyang bingwu
 
Static analysis of C++ source code
Static analysis of C++ source codeStatic analysis of C++ source code
Static analysis of C++ source codePVS-Studio
 
Static analysis of C++ source code
Static analysis of C++ source codeStatic analysis of C++ source code
Static analysis of C++ source codeAndrey Karpov
 

Similaire à Tgtd illustration (20)

[Ruxcon 2011] Post Memory Corruption Memory Analysis
[Ruxcon 2011] Post Memory Corruption Memory Analysis[Ruxcon 2011] Post Memory Corruption Memory Analysis
[Ruxcon 2011] Post Memory Corruption Memory Analysis
 
Osol Pgsql
Osol PgsqlOsol Pgsql
Osol Pgsql
 
IRQs: the Hard, the Soft, the Threaded and the Preemptible
IRQs: the Hard, the Soft, the Threaded and the PreemptibleIRQs: the Hard, the Soft, the Threaded and the Preemptible
IRQs: the Hard, the Soft, the Threaded and the Preemptible
 
[ZigBee 嵌入式系統] ZigBee 應用實作 - 使用 TI Z-Stack Firmware
[ZigBee 嵌入式系統] ZigBee 應用實作 - 使用 TI Z-Stack Firmware[ZigBee 嵌入式系統] ZigBee 應用實作 - 使用 TI Z-Stack Firmware
[ZigBee 嵌入式系統] ZigBee 應用實作 - 使用 TI Z-Stack Firmware
 
[CCC-28c3] Post Memory Corruption Memory Analysis
[CCC-28c3] Post Memory Corruption Memory Analysis[CCC-28c3] Post Memory Corruption Memory Analysis
[CCC-28c3] Post Memory Corruption Memory Analysis
 
RTOS implementation
RTOS implementationRTOS implementation
RTOS implementation
 
Interrupts
InterruptsInterrupts
Interrupts
 
Linux Network Stack
Linux Network StackLinux Network Stack
Linux Network Stack
 
[Kiwicon 2011] Post Memory Corruption Memory Analysis
[Kiwicon 2011] Post Memory Corruption Memory Analysis[Kiwicon 2011] Post Memory Corruption Memory Analysis
[Kiwicon 2011] Post Memory Corruption Memory Analysis
 
Linux-without-a-bootloader
Linux-without-a-bootloaderLinux-without-a-bootloader
Linux-without-a-bootloader
 
Code Red Security
Code Red SecurityCode Red Security
Code Red Security
 
Kernel Recipes 2015 - Porting Linux to a new processor architecture
Kernel Recipes 2015 - Porting Linux to a new processor architectureKernel Recipes 2015 - Porting Linux to a new processor architecture
Kernel Recipes 2015 - Porting Linux to a new processor architecture
 
[HITB Malaysia 2011] Exploit Automation
[HITB Malaysia 2011] Exploit Automation[HITB Malaysia 2011] Exploit Automation
[HITB Malaysia 2011] Exploit Automation
 
Gluster as Block Store in Containers
Gluster as Block Store in ContainersGluster as Block Store in Containers
Gluster as Block Store in Containers
 
Tierney bq207
Tierney bq207Tierney bq207
Tierney bq207
 
OpenDNSSEC RIPE58
OpenDNSSEC RIPE58OpenDNSSEC RIPE58
OpenDNSSEC RIPE58
 
A little systemtap
A little systemtapA little systemtap
A little systemtap
 
A little systemtap
A little systemtapA little systemtap
A little systemtap
 
Static analysis of C++ source code
Static analysis of C++ source codeStatic analysis of C++ source code
Static analysis of C++ source code
 
Static analysis of C++ source code
Static analysis of C++ source codeStatic analysis of C++ source code
Static analysis of C++ source code
 

Plus de Xu Wang

Hyper: 让Pod以VM为边界
Hyper: 让Pod以VM为边界Hyper: 让Pod以VM为边界
Hyper: 让Pod以VM为边界Xu Wang
 
Hyper 基于hypervisor的docker引擎.pptx
Hyper 基于hypervisor的docker引擎.pptxHyper 基于hypervisor的docker引擎.pptx
Hyper 基于hypervisor的docker引擎.pptxXu Wang
 
Rethink of PaaS
Rethink of PaaSRethink of PaaS
Rethink of PaaSXu Wang
 
Cassandra Technical and history overview
Cassandra Technical and history overviewCassandra Technical and history overview
Cassandra Technical and history overviewXu Wang
 
ZeroMQ简介
ZeroMQ简介ZeroMQ简介
ZeroMQ简介Xu Wang
 
何时浮云散尽(在北邮北邮纪阳老师移动互联网课程上的讲义)
何时浮云散尽(在北邮北邮纪阳老师移动互联网课程上的讲义)何时浮云散尽(在北邮北邮纪阳老师移动互联网课程上的讲义)
何时浮云散尽(在北邮北邮纪阳老师移动互联网课程上的讲义)Xu Wang
 
Metro Beijing
Metro BeijingMetro Beijing
Metro BeijingXu Wang
 
Cloud Computing Seminar with BUPT WTI
Cloud Computing Seminar with BUPT WTICloud Computing Seminar with BUPT WTI
Cloud Computing Seminar with BUPT WTIXu Wang
 
Hadoop development in China Mobile Research Institute
Hadoop development in China Mobile Research InstituteHadoop development in China Mobile Research Institute
Hadoop development in China Mobile Research InstituteXu Wang
 

Plus de Xu Wang (9)

Hyper: 让Pod以VM为边界
Hyper: 让Pod以VM为边界Hyper: 让Pod以VM为边界
Hyper: 让Pod以VM为边界
 
Hyper 基于hypervisor的docker引擎.pptx
Hyper 基于hypervisor的docker引擎.pptxHyper 基于hypervisor的docker引擎.pptx
Hyper 基于hypervisor的docker引擎.pptx
 
Rethink of PaaS
Rethink of PaaSRethink of PaaS
Rethink of PaaS
 
Cassandra Technical and history overview
Cassandra Technical and history overviewCassandra Technical and history overview
Cassandra Technical and history overview
 
ZeroMQ简介
ZeroMQ简介ZeroMQ简介
ZeroMQ简介
 
何时浮云散尽(在北邮北邮纪阳老师移动互联网课程上的讲义)
何时浮云散尽(在北邮北邮纪阳老师移动互联网课程上的讲义)何时浮云散尽(在北邮北邮纪阳老师移动互联网课程上的讲义)
何时浮云散尽(在北邮北邮纪阳老师移动互联网课程上的讲义)
 
Metro Beijing
Metro BeijingMetro Beijing
Metro Beijing
 
Cloud Computing Seminar with BUPT WTI
Cloud Computing Seminar with BUPT WTICloud Computing Seminar with BUPT WTI
Cloud Computing Seminar with BUPT WTI
 
Hadoop development in China Mobile Research Institute
Hadoop development in China Mobile Research InstituteHadoop development in China Mobile Research Institute
Hadoop development in China Mobile Research Institute
 

Dernier

Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 

Dernier (20)

Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 

Tgtd illustration

  • 1. tgtd illustration based on https://github.com/fujita/tgt Tuesday, November 8, 11 1
  • 2. General Arch epoll iSCSI, iSER, bst: aio, rdwr, FCoE, etc. null, sg, ssc low level backing initiator drivers con stores n R &W target mmc, osd, Core sbc, scc, smc, ssc lu SC a sk SI mt spc & tgtadm mgmt devices utils, common Tuesday, November 8, 11 2
  • 3. Mgmt Routine If req Len> tgtadm_req tgt_mgmt tgtadm send commands here mtask_handler HDR_RECV sys_mgmt PDU_RECV target_mgmt IPC: mgmt_task portal_mgmt device_mgmt mtask_handler RSP_SEND account_mgmt connection_mgmt Tuesday, November 8, 11 3
  • 4. State Transition of Conn Security Security Security auth Done Free Security login Security Login Login full full Only for iSER Init Start Full Kernel Ready Network Error Proto Error Logout Exit Close Scsi Tuesday, November 8, 11 4
  • 5. Cmd rx in iscsid 1 Immediate: OpXX iscsi_task_queue iscsi_task_ececute Other: OP_DATA_OUT expected SNs: iscsi_task_execute Others: iscsi_task_ececute Add to pending list NOOP_OUT/LOGOUT: Set EPOLLIN|EPOLLOUT queue: SCSI_CMD: target_cmd_queue ... target.c iscsi_scsi_cmd_execute all: SCSI_TMFUNC: Set EPOLLIN|EPOLLOUT iscsi_tm_execute target_mgmt_request ... target.c Tuesday, November 8, 11 5
  • 6. Cmd rx in iscsid 2 OpXX OP_DATA_OUT iscsi_data_out_rx_done Do nothing FINAL && not pending: iscsi_scsi_cmd_execute ... as in prev page Tuesday, November 8, 11 6
  • 7. SCSI Cmd Processing In target.c, scsi.c, & devs cmd_perform == scsi_cmd_perfor scsi_cmd_queued Processed later dev_type_template.ops[op]. cmd_perfor sbc_rw, sbc_sync_cache BS Others processed in sbc.c or spc.c Tuesday, November 8, 11 7
  • 8. Backing Storage bs_init bs_thread_info follows lu Create LU bs_open pathname, fd, size Dev request bs_cmd_submit(cmd) Destroy LU bs_close, bs_exit Tuesday, November 8, 11 8
  • 9. That's All. Thanks! Tuesday, November 8, 11 9