48
1 Организация подсистемы ввода-вывода CSS (Channel Subsystem) Лекция № 9

1 Организация подсистемы ввода-вывода CSS (Channel Subsystem) Лекция № 9

Embed Size (px)

Citation preview

1

Организация подсистемы ввода-вывода

CSS (Channel Subsystem)

Лекция № 9

2

Channel Paths, Control Units, and Devices

3

Device Numbers

• Devices (such as disks, printers, screens) are assigned device numbers from 0 to 0xFFFF by the system administrator.

• These numbers are used in communication between a system operator and the operating system.

• These numbers do not need to be contiguous in a configuration.

4

5

Subchannels

The IOCP (I/O configuration program) reads the I/O configuration input deck. It defines the relationship between:

– Channel paths– Control units and– Devices

•IOCP assign a subchannel number to each device.

•The numbers range from 0 to 0xFFFF and are contiguous.

6

Dynamic I/O Configuration

The I/O configuration may be changed under software control by adding or deleting

– Channel paths

– Control units

– Devices

The software front-end is known as HCD

(Hardware Configuration Definition)

7

8

Изменения в подканалах(Modification of Subchannels)

Часть блока SCHIB может быть изменена с помощью команды

MODIFY SUBCHANNEL (MSCH), а именно: – подкласс прерывания I/O (ISC); – бит применения (E).

• MSCH обычно хранит блок SCHIB который использован (retrieved) перед командой

START SUBCHANNEL (STSCH)

9

Starting an I/O operation

10

Starting an I/O operation

11

Operation-Request Block (ORB)• The interruption parameter is saved by the channel

subsystem and returned unchanged at the time of the I/O interrupt. It is normally used by the operating system to store the address of its own device control block.

• The logical path mask (LPM) can be used by the operating system to route an I/O operation to specific channel paths. Normally, the operating system sets this field to 0xFF to allow the channel subsystem to use any configured path.

• The channel program address points to the first channel command word (CCW).

12

13

Типы кодов команд управляющего слова канала CCW

CCW command code types: – Write (normal data output) – Read (normal data input) – Read backward (good for tapes) – Control (e.g. to position disk head)– Sense (retrieve reason for unit check)– Sense ID (retrieve device type, e.g.

3390)– Transfer in channel (branch in

channel program)

• The particular command code is device-specific

Коды операции CCW

Код операции

Выполняемые действия

~ ~ ~ ~ 0 0 0 0 не используется

m m m m m m 0 1 записать

m m m m m m 1 0 прочитать

m m m m 1 1 0 0 прочитать в обратном направлении

m m m m m m 1 1 управление

m m m m 0 1 0 0 прочитать состояние

1 1 1 0 0 1 0 0 прочитать уточненное состояние

~ ~ ~ ~ 1 0 0 0 переход в канале (формат 0)

0 0 0 0 1 0 0 0 переход в канале (формат 1)

m m m m 1 0 0 0 не используетсяm - биты модификации кодов в зависимости от типов устройств

14

CCW Flags

• CD: chain data (use the same CCW command on the next CCW)

• CC: chain command (0 = this is the last CCW)• SLI: suppress incorrect length indication• SKP: do not read data on input• PCI: program-controlled interruption (generate

intermediate I/O interrupt when this CCW is fetched)

• IDA: indirect data addressing• S: suspend channel program without generating

I/O interrupt

15

Indirect-Data-Address Words (IDAWs)

• IDAWs are used to describe I/O buffers that are contiguous in virtual storage – and thus usually scattered in absolute storage.

– With z/Architecture, they provide the only means to address data buffers above 2G.

• IDAWs are used when the IDA flag is set in the CCW. The address in the CCW points to the list of IDAWs.– Format-1 IDAWs are 32 bits long and cover up to 2K of storage– Format-2 IDAWs are 64 bits long and cover up to 4K of storage

• When ORB word 1.14 (H) is 1, format-2 IDAWs are used. When ORB word 1.15 (T) is also 1, the IDAWs cover a 2K area, otherwise, they cover 4K.

16

Indirect-Data-Address Words (IDAWs)

17

Conclusion of I/O Operations

• When the last CCW has been processed, the channel signals ending status to the channel subsystem

• The subchannel is now made status-pending and an interruption condition is generated for its I/O-interruption subclass (ISC)

• An I/O interrupt is said to be floating, i.e. it is “offered” to all CPUs that are enabled for this ISC

• If more than one CPU is enabled for this I/O interrupt, only one will actually take it

• As an alternative, the CPU may poll for an interrupt using the TEST PENDING INTERRUPTION (TPI) instruction

18

Conclusion of I/O Operations

19

Conclusion of I/O Operations

20

Conclusion of I/O Operations

21

Conclusion of I/O Operations

22

Способы выполнения канальных программ

В зависимости от типа каналов в z/Architecture возможны три способа выполнения канальных программ:

– байт-мультиплексный (byte-multiplex mode); – блок-мультиплексный (burst mode); – фрейм-мультиплексный (frame-multiplex

mode).

23

Структура фрейма

24

z990 Extensions to I/O Architecture

• Multiple channel subsystems (MCSS)

• 1 to 4 logical channel subsystems (LCSS)– Up to 256 channel paths per logical partition (LPAR)

– Up to 63K devices (subchannels) per LPAR

– An LCSS may be shared by multiple LPARs

• Allows much larger configurations (e.g. To consolidate two z900 systems on a single z990)

25

z990 – I/O Configuration Support

26

z990 – I/O Configuration Support

27

z9 Extensions to I/O Architecture• Multiple subchannel sets (MSS)• The problem: z990 had only one subchannel set– 64,512 subchannels (1,024 reserved for internal use)• This became a problem for large installations because

of PAV (parallel access volumes):– With PAV, a single disk drive often consumes four

subchannels (base address plus three aliases)• The solution z9 supports two subchannel sets– 65,280 subchannels in set 0 (256 reserved for internal use)– 65,535 subchannels in set 1• z/OS 1.7 exploits second subchannel set to access alias

addresses of parallel access volumes (PAV)

28

z9 – I/O Configuration Growth - MultipleSubchannel Sets (MSS)

29

z9 – Multiple Subchannel Sets per LCSS

30

Modified Indirect-Data-Address Words (MIDAWs)

• MIDAWs were invented to increase I/O throughput by reducing the number of CCWs required.

• Like IDAWs, MIDAWs specify a list of data areas in absolute storage.

• Unlike IDAWs, MIDAWs are used to describe I/O buffers that are scattered in virtual storage:

– MIDAWs never have to specify aligned addresses (the areas must not cross 4K-boundaries, though).– Each MIDAW has its own count field.

• MIDAWs were introduced with the IBM System z9.• Use of MIDAWs must be enabled in the ORB (D-bit, word 1, bit 25).• The MIDA flag must be set in the flags of the CCW (bit 15 in

format-1 CCW). When it is used, neither IDA nor SKIP flags must be set.

• The CCW points to a list of MIDAWs (MIDAL).• The MIDAL begins on a quadword boundary. It must not cross a 4K

boundary.

31

MIDAW layout

32

Initial Program Loading(IPL)

• Boots the operating system from an I/O device

• Initiated manually at the support element (SE) or hardware management console (HMC)

• System operator specifies device number

• Operator may specify an IPL parameter that is retrieved later by the operating system with a SERVICE CALL instruction (SERVC, also known as SCLP)

33

Initial Program Loading (IPL)

34

IPL Process

35

Функциональный состав CSS

• Настройка и управление ПУ

• Операции ввода-вывода

• виртуальные соединения между логическими разделами сервера

• Channel Subsystem – CSS

• канальные программы Channel Programs

• Внутренние каналы = подканалы Subchannels

36

Варианты исполнения CSS

37

Варианты исполнения CSS

38

Общая организация канальной подсистемы CSS

39

Параметры канальных подсистемПараметры канальных подсистем

 S390

(G5/G6)z800, z900 z990

CSS 1 на сервер 1 на сервер 2 на сервер

Логические разделы

15 на сервер 15 на сервер 15 на LCSS 30 на сервер

Подканалы 288 К на сервер

512 К на сервер

945 К на LCSS 1890 К на сервер

Канальные пути

256 на CSS 256 на сервер

256 на сервер 256 на LCSS

256 на CSS 512 на сервер

Периферийные устройства

36 К на сервер

63 К на сервер

63 К на LCSS 126 К на сервер

40

Адресация в подсистеме ввода-вывода

41

Идентификация объектов канальной системы

42

Формат команды ввода-вывода

Адресация устройств в командах ввода-вывода

0 15

19 31

Команда ввода-вывода

COP B2 D2

0 31

47 63

GR 1 0000000000000001 SCBNUM

43

Идентификация объектов канальной системы

Идентификатор подсистемы0 31 39 43 47 63

˜ CSSID IID 0001 SCBNUM

44

Принципы выполнения операций ввода-

вывода в канальных подсистемах

• Распараллеливание работы большого числа периферийных устройств

• Каждой операции ввода-вывода

• Параллельно функционирующие каналы в CSS

• своя канальная программа, определяющая параметры обмена

• каналы реализуются как процессоры со специализированной системой команд

45

Принципы выполнения

операций ввода-вывода в

базовой архитектуре

46

Принципы выполнения

операций ввода-вывода в

базовой архитектуре

47

Выполнение операций

ввода-вывода в архитектуре

zSeries

48

Основные отличия канальной подсистемы

z/Architecture от базовой архитектуры