{"id":372,"date":"2012-01-15T14:50:55","date_gmt":"2012-01-15T20:50:55","guid":{"rendered":"http:\/\/tommysprinkle.com\/txxos\/?p=372"},"modified":"2021-04-17T18:21:23","modified_gmt":"2021-04-17T23:21:23","slug":"io-management","status":"publish","type":"post","link":"https:\/\/tommysprinkle.com\/txxos\/?p=372","title":{"rendered":"I\/O Management"},"content":{"rendered":"<p>With the basic\u00a0Dispatcher\u00a0functions up and running we can now turn to I\/O management. \u00a0Our I\/O\u00a0management\u00a0code will consist\u00a0of several components. \u00a0We will need a control block to keep the status of each device. \u00a0For this we will use a Unit Control Block (UCB). \u00a0Each device we manage will have a UCB in our UCB Table. \u00a0The UCB&#8217;s are chained together and must be defined in sequence based on the Device Address (CUA).<\/p>\n<p>We will then need a component to schedule and queue I\/O requests. \u00a0If a device is available the I\/O request can immediately be issued. \u00a0If the device is busy processing another request the new one will be placed in a queue anchored off the UCB. \u00a0An I\/O request will be represented by a control block, the I\/O Request Block (IORB).<\/p>\n<p>When an I\/O request is completed by the device an interrupt will be generated. \u00a0We will then need an I\/O Interrupt processing routine to signal the originator of the request and start the next queued request for the device.<\/p>\n<p>We will also build a SVC interface to the I\/O scheduler. \u00a0The SVC will take a control block, the I\/O Block (IOB) and will build the IORB and then call the I\/O Scheduler. \u00a0It will also provide for posting an ECB when the I\/O is complete.<\/p>\n<p>Finally we will begin work on a 3270 Console that will use the SVC I\/O interface.<\/p>\n<p>In building and testing the I\/O code I found and corrected a few bugs in the previous code. \u00a0I had to fix the Nucleus Loader because when the Nucleus Load Module required loading two blocks of data the second was being loaded at the wrong location in memory.<\/p>\n<p>I also discovered a bug in the Wait SVC processing. \u00a0If the Wait SVC was called and the ECB was already posted the SVC was exiting to the Dispatcher instead of exiting through the Exit Routine. \u00a0This resulted in leaving the RB associated with the Wait SVC on the TCB RB Chain. \u00a0The fix was to use the Exit Routine which deletes the RB.<\/p>\n<p>[Next &#8211; <a title=\"Unit Control Block \u2013 @UCB\" href=\"http:\/\/tommysprinkle.com\/txxos\/?p=374\">Unit Control Block &#8211; @UCB<\/a>]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>With the basic\u00a0Dispatcher\u00a0functions up and running we can now turn to I\/O management. \u00a0Our I\/O\u00a0management\u00a0code will consist\u00a0of several components. \u00a0We will need a control block to keep the status of each device. \u00a0For this we will use a Unit Control &hellip; <a href=\"https:\/\/tommysprinkle.com\/txxos\/?p=372\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"template-page-builder-no-sidebar.php","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[1],"tags":[],"class_list":["post-372","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p1CPQT-60","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/tommysprinkle.com\/txxos\/index.php?rest_route=\/wp\/v2\/posts\/372","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tommysprinkle.com\/txxos\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tommysprinkle.com\/txxos\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tommysprinkle.com\/txxos\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/tommysprinkle.com\/txxos\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=372"}],"version-history":[{"count":3,"href":"https:\/\/tommysprinkle.com\/txxos\/index.php?rest_route=\/wp\/v2\/posts\/372\/revisions"}],"predecessor-version":[{"id":472,"href":"https:\/\/tommysprinkle.com\/txxos\/index.php?rest_route=\/wp\/v2\/posts\/372\/revisions\/472"}],"wp:attachment":[{"href":"https:\/\/tommysprinkle.com\/txxos\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=372"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tommysprinkle.com\/txxos\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=372"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tommysprinkle.com\/txxos\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=372"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}