1. A semiconductor device comprising a device, the device including: a decoder which analyzes a command of a received packet to determine processing specified by the packet; a generation circuit which generates a unique device number in accordance with information in the packet; a register which holds the generated unique device number; and a modifier which updates and outputs the packet, wherein when a packet issued by a host is a command packet, among broadcast packets which return to the host through one or more devices, for determining the unique device number, the command packet includes parameters of an initial value and final value of device number, the device, when the device detects that the device first receives the command packet for determining the unique device number, determines device number in accordance with the initial value of the received command packet, sets the determined device number to the register, updates the initial value and the final value in the command packet to the determined device number, and transmits the command packet to a next device or the host, and when the device detects that the device does not first receive the command packet for determining the unique device number, calculates device number different from determined device number of another device based on the initial value and/or the final value in the received command packet, set the calculated device number to the register, updates the final value to the calculated device number without updating the initial value in the command packet, and transmits the command packet to a next device or the host.